import java.applet.AppletContext;
import java.awt.Color;
import java.awt.Component;
import java.awt.Graphics;
import java.io.DataInputStream;
import java.io.FileInputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.ObjectInputStream;
import java.io.OutputStream;
import java.math.BigInteger;
import java.net.InetAddress;
import java.net.URL;
import java.util.Calendar;
import java.util.Date;
import java.util.zip.CRC32;

public final class Client extends Applet {
	private static final long serialVersionUID = -1958504436460061412L;
	private int[] anIntArray837 = new int[9];
	private byte[][] aByteArrayArray838;
	private String aString839 = "";
	private static BigInteger aBigInteger840 = (new BigInteger(
		"7162900525229798032761816791230527296329313291232324290237849263501208207972894053929065636522363163621000728841182238772712427862772219676577293600221789"));
	private static int anInt841;
	private int[] anIntArray842 = { 16776960, 16711680, 65280, 65535, 16711935, 16777215 };
	private int[] anIntArray843 = new int[Skills.skillCount];
	private int anInt844;
	private int anInt845;
	private int anInt846;
	private int anInt847;
	private int anInt848;
	private String[] friendNames = new String[200];
	private int anInt850;
	private int anInt851;
	private int[] anIntArray852 = new int[5];
	private int anInt853;
	private int anInt854 = 2;
	private int anInt855;
	private int[] anIntArray856;
	private int[] anIntArray857;
	private int[] anIntArray858;
	private int friendCount;
	private int anInt860;
	private String aString861 = "";
	private int anInt862;
	private String[] aStringArray863 = new String[100];
	private int[] anIntArray864 = new int[100];
	private int anInt865;
	private boolean aBoolean866 = false;
	private int anInt867;
	static boolean aBoolean868;
	private int packetSize;
	private int opcode;
	private int anInt871;
	private int anInt872;
	private int anInt873;
	private int anInt874;
	private int anInt875;
	private int anInt876;
	private int anInt877;
	private int anInt878;
	private int[][][] anIntArrayArrayArray879 = new int[4][13][13];
	private IndexedSprite aIndexedSprite_880;
	private IndexedSprite aIndexedSprite_881;
	private IndexedSprite aIndexedSprite_882;
	private IndexedSprite aIndexedSprite_883;
	private IndexedSprite aIndexedSprite_884;
	private int[][] anIntArrayArray885 = new int[104][104];
	private int[][] anIntArrayArray886 = new int[104][104];
	private int anInt887;
	private Archive aArchive_888;
	private int anInt889;
	private int anInt890;
	private int[][][] anIntArrayArrayArray891;
	private boolean aBoolean892 = false;
	private int anInt893;
	private int anInt894 = -992;
	private static int anInt895;
	private Sprite[] aSpriteArray896 = new Sprite[8];
	private int anInt897 = 559;
	private byte aByte898 = 6;
	private IsaacCipher cryption;
	private boolean aBoolean900 = false;
	private byte aByte901 = -123;
	long aLong902;
	private int anInt903;
	private int anInt904;
	private int anInt905;
	private GraphicsBuffer aGraphicsBuffer_906;
	private GraphicsBuffer aGraphicsBuffer_907;
	private GraphicsBuffer aGraphicsBuffer_908;
	private GraphicsBuffer aGraphicsBuffer_909;
	private GraphicsBuffer aGraphicsBuffer_910;
	private GraphicsBuffer aGraphicsBuffer_911;
	private GraphicsBuffer aGraphicsBuffer_912;
	private GraphicsBuffer aGraphicsBuffer_913;
	private GraphicsBuffer aGraphicsBuffer_914;
	private int anInt915;
	private int anInt916;
	private int anInt917 = 2;
	private boolean aBoolean918 = true;
	private boolean aBoolean919 = true;
	private int[] anIntArray920 = new int[151];
	private int anInt921 = 8;
	private int anInt922;
	private static int anInt923 = 10;
	static int anInt924;
	private static boolean aBoolean925 = true;
	private static boolean aBoolean926;
	private boolean[] aBooleanArray927 = new boolean[5];
	private int anInt928 = -188;
	private Packet aPacket_929 = Packet.create(1);
	private long aLong930;
	private int anInt931 = 2301979;
	private int spriteDrawX = -1;
	private int spriteDrawY = -1;
	private boolean aBoolean934 = true;
	private int anInt935 = -1;
	private byte aByte936 = -113;
	private String aString937 = "";
	private int anInt938 = -214;
	private int anInt939;
	private int anInt940 = 50;
	private int[] anIntArray941 = new int[anInt940];
	private int[] anIntArray942 = new int[anInt940];
	private int[] anIntArray943 = new int[anInt940];
	private int[] anIntArray944 = new int[anInt940];
	private int[] anIntArray945 = new int[anInt940];
	private int[] anIntArray946 = new int[anInt940];
	private int[] anIntArray947 = new int[anInt940];
	private String[] aStringArray948 = new String[anInt940];
	private String aString949 = "";
	private boolean aBoolean950 = false;
	private int anInt951;
	private static int[] anIntArray952 = new int[99];
	private boolean aBoolean953 = false;
	private Sprite[] headicons_hint = new Sprite[32];
	private int anInt955;
	private byte aByte956 = 1;
	private String aString957 = "";
	private String aString958 = "";
	private boolean aBoolean959 = true;
	private int anInt960 = -1;
	private int anInt961 = -1;
	public static boolean aBoolean962;
	private static boolean aBoolean963;
	private Packet aPacket_964 = Packet.create(1);
	private IndexedSprite backbase1;
	private IndexedSprite backbase2;
	private IndexedSprite backhmid1;
	private int anInt968 = 2048;
	private int anInt969 = 2047;
	private Player[] totalPlayers = new Player[anInt968];
	private int playerCount;
	int[] playerIndices = new int[anInt968];
	private int anInt973;
	private int[] anIntArray974 = new int[anInt968];
	private Packet[] aPacketArray975 = new Packet[anInt968];
	private IndexedSprite[] sideicons = new IndexedSprite[13];
	private int anInt977;
	private static int anInt978;
	private int[] anIntArray979 = new int[500];
	private int[] anIntArray980 = new int[500];
	private int[] anIntArray981 = new int[500];
	private int[] anIntArray982 = new int[500];
	private IndexedSprite aIndexedSprite_983;
	private IndexedSprite aIndexedSprite_984;
	private IndexedSprite aIndexedSprite_985;
	private IndexedSprite aIndexedSprite_986;
	private IndexedSprite aIndexedSprite_987;
	private int anInt988 = -1;
	private int anInt989;
	private int anInt990;
	private int[] anIntArray991 = new int[5];
	private int anInt992;
	private int anInt993;
	private int anInt994;
	private int anInt995;
	private int anInt996;
	private int anInt997;
	private int anInt998;
	private static boolean aBoolean999;
	private int[] anIntArray1000;
	private int[] anIntArray1001;
	private int[] anIntArray1002;
	private int[] anIntArray1003;
	private int anInt1004;
	private int[] anIntArray1005 = new int[2000];
	private int anInt1006;
	private static String aString1007;
	static final int[][] anIntArrayArray1008;
	private int anInt1009;
	private int anInt1010 = 2;
	int anInt1011;
	int anInt1012;
	private static int anInt1013;
	private boolean aBoolean1014 = false;
	private int anInt1015;
	private boolean aBoolean1016 = false;
	private Sprite aSprite_1017;
	private Sprite aSprite_1018;
	private int[] anIntArray1019 = new int[151];
	private int anInt1020;
	private int anInt1021;
	private int anInt1022;
	private int anInt1023;
	private Socket socket;
	private static int anInt1025;
	private String aString1026 = "";
	private String aString1027;
	private boolean aBoolean1028 = false;
	private int[] anIntArray1029 = new int[Skills.skillCount];
	private int anInt1030;
	private Sprite[] mapfunctions = new Sprite[100];
	private final int[] anIntArray1032 = { 0, 0, 0, 0, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
		2, 2, 2, 3 };
	private boolean aBoolean1033 = false;
	private int anInt1034;
	private int anInt1035;
	private Sprite aSprite_1036;
	private Sprite aSprite_1037;
	private boolean aBoolean1038 = true;
	public int[] anIntArray1039 = new int[2000];
	private int anInt1040;
	private int anInt1041;
	private int anInt1042;
	private int anInt1043;
	private int anInt1044;
	private int anInt1045;
	private boolean aBoolean1046 = false;
	private int anInt1047;
	private int anInt1048;
	private static int anInt1049;
	private int anInt1050;
	private int anInt1051 = 69;
	private static int anInt1052;
	private int anInt1053 = -1;
	private int[] anIntArray1054 = new int[Skills.skillCount];
	private int anInt1055 = 2;
	private int anInt1056 = 3;
	private int anInt1057;
	private String aString1058;
	private Font aFont_1059;
	private Font aFont_1060;
	private Font aFont_1061;
	private Font aFont_1062;
	private int anInt1063;
	private int anInt1064;
	private boolean aBoolean1065 = false;
	private byte aByte1066 = 1;
	private boolean aBoolean1067 = false;
	private int anInt1068;
	private String[] aStringArray1069 = new String[5];
	private boolean[] aBooleanArray1070 = new boolean[5];
	private int anInt1071;
	private int anInt1072 = 20411;
	private long[] aLongArray1073 = new long[100];
	private boolean aBoolean1074 = false;
	private int anInt1075;
	private int anInt1076;
	private int[] anIntArray1077 = new int[1000];
	private int[] anIntArray1078 = new int[1000];
	private Sprite[] headicons_prayer = new Sprite[32];
	private int anInt1080 = 5063219;
	private int[] anIntArray1081 = { -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1 };
	private static int anInt1082;
	private int anInt1083;
	private int[] anIntArray1084;
	private int[] anIntArray1085;
	private Sprite overlay_multiway;
	private int anInt1087;
	private CRC32 aCRC32_1088 = new CRC32();
	private int anInt1089 = -1;
	private int[] anIntArray1090 = new int[50];
	private int anInt1091;
	private String aString1092 = "";
	private String aString1093 = "";
	private int anInt1094;
	private IndexedSprite aIndexedSprite_1095;
	private IndexedSprite aIndexedSprite_1096;
	private boolean aBoolean1097 = false;
	private boolean aBoolean1098 = false;
	private int[] anIntArray1099 = new int[5];
	private static int anInt1100;
	private int anInt1101;
	private Sprite aSprite_1102;
	private Sprite aSprite_1103;
	private String aString1104 = "";
	private int[] anIntArray1105 = new int[5];
	private int anInt1106;
	private int anInt1107 = 78;
	private GraphicsBuffer aGraphicsBuffer_1108;
	private GraphicsBuffer aGraphicsBuffer_1109;
	private GraphicsBuffer aGraphicsBuffer_1110;
	private int anInt1111;
	private int anInt1112;
	private int anInt1113;
	private int anInt1114;
	private int anInt1115;
	private Sprite compass;
	private IndexedSprite[] aIndexedSpriteArray1117;
	private int anInt1118;
	private int anInt1119 = -30658;
	private int anInt1120;
	private int anInt1121;
	private Sprite aSprite_1122;
	private int[] anIntArray1123 = new int[4000];
	private int[] anIntArray1124 = new int[4000];
	private byte[][][] aByteArrayArrayArray1125;
	private int anInt1126;
	private boolean aBoolean1127 = false;
	private int anInt1128;
	private int anInt1129;
	private long[] friendNameForLong = new long[200];
	private Packet aPacket_1131 = new Packet(new byte[5000]);
	private Npc[] totalNpcs = new Npc[16384];
	private int npcCount;
	int[] anIntArray1134 = new int[16384];
	private int anInt1135 = 7759444;
	private boolean aBoolean1136 = false;
	public boolean aBoolean1137 = false;
	private int anInt1138;
	private static int anInt1139;
	private int anInt1140 = -110;
	private long aLong1141;
	private IndexedSprite[] mod_icons = new IndexedSprite[2];
	private byte aByte1143 = -80;
	private boolean aBoolean1144 = true;
	private int[] anIntArray1145 = new int[5];
	private int anInt1146;
	private int anInt1147;
	private int anInt1148;
	private int anInt1149;
	String aString1150;
	private int anInt1151;
	private int anInt1152;
	private IndexedSprite[] mapscenes = new IndexedSprite[100];
	private int anInt1154 = -916;
	private boolean aBoolean1155 = false;
	private GraphicsBuffer aGraphicsBuffer_1156;
	private GraphicsBuffer aGraphicsBuffer_1157;
	private GraphicsBuffer aGraphicsBuffer_1158;
	private GraphicsBuffer aGraphicsBuffer_1159;
	private static int anInt1160;
	private byte aByte1161 = 97;
	private static int anInt1162;
	private boolean aBoolean1163 = false;
	private Class22 aClass22_1164;
	private static int anInt1165;
	private int[] anIntArray1166 = new int[256];
	static Player myPlayer;
	private static int anInt1168;
	private int anInt1169 = -1;
	private int anInt1170;
	private int anInt1171;
	private int anInt1172;
	private int anInt1173;
	String aString1174;
	private int anInt1175 = -89;
	private int[] anIntArray1176;
	private int[] anIntArray1177;
	private int anInt1178 = 300;
	private int anInt1179;
	private int[] anIntArray1180 = new int[33];
	private boolean drawInventoryRequest = false;
	private Sprite[] hitmarks = new Sprite[20];
	private int anInt1183;
	private String[] aStringArray1184 = new String[500];
	private IndexedSprite invback;
	private IndexedSprite mapback;
	private IndexedSprite chatback;
	private Packet inputStream = Packet.create(1);
	private int[][] anIntArrayArray1189 = new int[104][104];
	private static boolean aBoolean1190;
	private int anInt1191 = -1;
	private Sprite aSprite_1192;
	private Sprite aSprite_1193;
	private Sprite aSprite_1194;
	private Sprite aSprite_1195;
	private Sprite aSprite_1196;
	private int anInt1197;
	private GraphicsBuffer aGraphicsBuffer_1198;
	private GraphicsBuffer aGraphicsBuffer_1199;
	private GraphicsBuffer aGraphicsBuffer_1200;
	private GraphicsBuffer aGraphicsBuffer_1201;
	private GraphicsBuffer aGraphicsBuffer_1202;
	private GraphicsBuffer aGraphicsBuffer_1203;
	private GraphicsBuffer aGraphicsBuffer_1204;
	private GraphicsBuffer aGraphicsBuffer_1205;
	private GraphicsBuffer aGraphicsBuffer_1206;
	private static boolean aBoolean1207;
	private int anInt1208;
	private boolean aBoolean1209 = false;
	private Deque aDeque_1210 = new Deque(true);
	private boolean aBoolean1211 = false;
	private boolean aBoolean1212 = false;
	private int anInt1213 = -1;
	public static int[] anIntArray1214;
	private int anInt1215;
	private int anInt1216;
	private int anInt1217;
	private int anInt1218;
	private int anInt1219;
	private int anInt1220;
	private int anInt1221;
	private int anInt1222;
	private int anInt1223;
	private java.net.Socket aSocket1224;
	private int anInt1225;
	private int anInt1226;
	private int anInt1227;
	CacheIndex[] aCacheIndexArray1228 = new CacheIndex[5];
	private long aLong1229;
	private static int anInt1230;
	private int anInt1231 = -1;
	private byte[][] aByteArrayArray1232;
	private int anInt1233;
	private int anInt1234 = 1;
	private static int anInt1235;
	private int anInt1236 = 326;
	private static int anInt1237;
	private int anInt1238;
	private boolean aBoolean1239 = false;
	private boolean aBoolean1240 = false;
	private int anInt1241;
	private static boolean aBoolean1242;
	private volatile boolean aBoolean1243 = false;
	private int anInt1244;
	private byte[] aByteArray1245 = new byte[16384];
	private int anInt1246;
	private Sprite mapedge;
	Class7 aClass7_1248;
	private Interface anIComponent_1249 = new Interface();
	private long aLong1250;
	private int anInt1251 = 128;
	private int anInt1252;
	private int anInt1253;
	private int anInt1254;
	private int anInt1255;
	private int anInt1256 = 1;
	private final int anInt1257 = 100;
	private int[] anIntArray1258 = new int[100];
	private int[] anIntArray1259 = new int[50];
	private CollisionMap[] aCollisionMapArray1260 = new CollisionMap[4];
	private Deque aDeque_1261 = new Deque(true);
	private int anInt1262;
	private int anInt1263;
	private int anInt1264;
	private boolean aBoolean1265 = false;
	private boolean aBoolean1266 = true;
	private int[] friendNodeIds = new int[200];
	static final int[] anIntArray1268;
	private int anInt1269;
	private int anInt1270;
	private boolean aBoolean1271 = true;
	private int anInt1272 = -1;
	private int anInt1273;
	private boolean aBoolean1274 = true;
	boolean aBoolean1275 = true;
	private int anInt1276 = -1;
	private boolean aBoolean1277 = false;
	private Sprite[] aSpriteArray1278 = new Sprite[1000];
	private int anInt1279 = -1;
	private int anInt1280;
	private int anInt1281 = -939;
	private Deque aDeque_1282 = new Deque(true);
	private boolean aBoolean1283 = false;
	private int anInt1284;
	private int anInt1285 = 3;
	private int[] anIntArray1286 = new int[33];
	private int anInt1287 = 3353893;
	private Sprite[] headicons_pk = new Sprite[32];
	private int anInt1289;
	int[] anIntArray1290 = { 17, 24, 34, 40 };
	private Class32_Sub1 aClass32_Sub1_1291;
	private IndexedSprite aIndexedSprite_1292;
	private IndexedSprite aIndexedSprite_1293;
	private int anInt1294;
	int[] anIntArray1295 = new int[1000];
	private int[] anIntArray1296 = new int[100];
	private String[] aStringArray1297 = new String[100];
	private String[] aStringArray1298 = new String[100];
	int anInt1299;
	private int anInt1300;
	private boolean aBoolean1301 = true;
	private int anInt1302;
	private int anInt1303;
	private int anInt1304;
	private int anInt1305;
	private int anInt1306;
	private int anInt1307;
	private int anInt1308;
	static int anInt1309;
	private int[] anIntArray1310;
	private int[] anIntArray1311;
	private int[] anIntArray1312;
	private int[] anIntArray1313;
	private volatile boolean aBoolean1314 = false;
	private int anInt1315;
	private static BigInteger aBigInteger1316;
	private byte aByte1317 = -58;
	private int anInt1318 = 416;
	private int anInt1319;
	private volatile boolean aBoolean1320 = false;
	private int[] anIntArray1321 = new int[50];
	private int anInt1322;
	private Deque[][][] aDequeArrayArrayArray1323 = new Deque[4][104][104];
	private int anInt1324;
	static int anInt1325;
	private int[] anIntArray1326 = new int[7];
	private int anInt1327 = -1;
	private int anInt1328 = 409;
	private int anInt1329;
	private int anInt1330;
	private int anInt1331;
	private int anInt1332;
	public static int anInt1333;

	public final void method14(String string, int i) {
		if (string == null || string.length() == 0) {
			anInt862 = 0;
		} else {
			String string_0_ = string;
			String[] strings = new String[100];
			int i_1_ = 0;
			for (;;) {
				int i_2_ = string_0_.indexOf(" ");
				if (i_2_ == -1) {
					break;
				}
				String string_3_ = string_0_.substring(0, i_2_).trim();
				if (string_3_.length() > 0) {
					strings[i_1_++] = string_3_.toLowerCase();
				}
				string_0_ = string_0_.substring(i_2_ + 1);
			}
			string_0_ = string_0_.trim();
			if (string_0_.length() > 0) {
				strings[i_1_++] = string_0_.toLowerCase();
			}
			anInt862 = 0;
			if (i != 2) {
				aBoolean959 = !aBoolean959;
			}
			while_7_: for (int i_4_ = 0; i_4_ < ItemDefinition.anInt335; i_4_++) {
				ItemDefinition itemDefinition = ItemDefinition.method212(i_4_);
				if (itemDefinition.anInt343 == -1 && itemDefinition.examine != null) {
					String string_5_ = itemDefinition.examine.toLowerCase();
					for (int i_6_ = 0; i_6_ < i_1_; i_6_++) {
						if (string_5_.indexOf(strings[i_6_]) == -1) {
							continue while_7_;
						}
					}
					aStringArray863[anInt862] = string_5_;
					anIntArray864[anInt862] = i_4_;
					anInt862++;
					if (anInt862 >= aStringArray863.length) {
						break;
					}
				}
			}
		}
	}

	public final void method15(boolean bool) {
		aPacket_964.putOpcode(110);
		if (bool) {
			aDequeArrayArrayArray1323 = null;
		}
		if (anInt1089 != -1) {
			method44(Client.aBoolean1190, anInt1089);
			anInt1089 = -1;
			drawInventoryRequest = true;
			aBoolean1239 = false;
			aBoolean950 = true;
		}
		if (anInt988 != -1) {
			method44(Client.aBoolean1190, anInt988);
			anInt988 = -1;
			aBoolean1240 = true;
			aBoolean1239 = false;
		}
		if (anInt1053 != -1) {
			method44(Client.aBoolean1190, anInt1053);
			anInt1053 = -1;
			aBoolean1046 = true;
		}
		if (anInt960 != -1) {
			method44(Client.aBoolean1190, anInt960);
			anInt960 = -1;
		}
		if (anInt1169 != -1) {
			method44(Client.aBoolean1190, anInt1169);
			anInt1169 = -1;
		}
	}

	private final void method16(int i, byte i_7_, Packet packet) {
		while (packet.bitPos + 10 < i * 8) {
			int i_8_ = packet.readBits(11);
			if (i_8_ == 2047) {
				break;
			}
			if (totalPlayers[i_8_] == null) {
				totalPlayers[i_8_] = new Player();
				if (aPacketArray975[i_8_] != null) {
					totalPlayers[i_8_].method583(aPacketArray975[i_8_], 0);
				}
			}
			((Client) this).playerIndices[playerCount++] = i_8_;
			Player player = totalPlayers[i_8_];
			((ObjectInstance) player).anInt1585 = Client.anInt1325;
			int i_9_ = packet.readBits(5);
			if (i_9_ > 15) {
				i_9_ -= 32;
			}
			int i_10_ = packet.readBits(1);
			if (i_10_ == 1) {
				anIntArray974[anInt973++] = i_8_;
			}
			int i_11_ = packet.readBits(1);
			int i_12_ = packet.readBits(5);
			if (i_12_ > 15) {
				i_12_ -= 32;
			}
			player.method579((((ObjectInstance) Client.myPlayer).anIntArray1587[0])
				+ i_12_, (byte) 5, i_11_ == 1,
				(((ObjectInstance) Client.myPlayer).anIntArray1586[0]) + i_9_);
		}
		packet.finishBitAccess();
		if (i_7_ == 6) {
			boolean bool = false;
		} else {
			opcode = -1;
		}
	}

	private void getRsaKeys() {
		try {
			final ObjectInputStream oin = new ObjectInputStream(new FileInputStream("public.key"));
			Client.aBigInteger840 = (BigInteger) oin.readObject();
			Client.aBigInteger1316 = (BigInteger) oin.readObject();
		} catch (final Exception ex) {
			System.err.println("Cannot find public RSA key file! Shutting down...");
			System.exit(1);
		}
	}

	public static final void main(String[] strings) {
		try {
			System.out.println("RS2 user Client - release #" + 377);
			if (strings.length != 5) {
				System.out
					.println("Usage: node-id, port-offset, [lowmem/highmem], [free/members], storeid");
			} else {
				Client.anInt923 = Integer.parseInt(strings[0]);
				Client.anInt924 = Integer.parseInt(strings[1]);
				if (strings[2].equals("lowmem")) {
					Client.method101(true);
				} else if (strings[2].equals("highmem")) {
					Client.method27(true);
				} else {
					System.out
						.println("Usage: node-id, port-offset, [lowmem/highmem], [free/members], storeid");
					return;
				}
				if (strings[3].equals("free")) {
					Client.aBoolean925 = false;
				} else if (strings[3].equals("members")) {
					Client.aBoolean925 = true;
				} else {
					System.out
						.println("Usage: node-id, port-offset, [lowmem/highmem], [free/members], storeid");
					return;
				}
				Signlink.storeid = Integer.parseInt(strings[4]);
				Signlink.startpriv(InetAddress.getLocalHost());
				Client client = new Client();
				client.getRsaKeys();
				client.method1(Client.anInt1025, 503, 765);
			}
		} catch (Exception exception) {
			/* empty */
		}
	}

	public final void method17() {
		aBoolean1320 = true;
		aDequeArrayArrayArray1323 = null;
		try {
			long l = System.currentTimeMillis();
			int i_13_ = 0;
			int i_14_ = 20;
			while (aBoolean1243) {
				anInt1101++;
				method81((byte) 1);
				method81((byte) 1);
				method98(47);
				if (++i_13_ > 10) {
					long l_15_ = System.currentTimeMillis();
					int i_16_ = (int) (l_15_ - l) / 10 - i_14_;
					i_14_ = 40 - i_16_;
					if (i_14_ < 5) {
						i_14_ = 5;
					}
					i_13_ = 0;
					l = l_15_;
				}
				try {
					Thread.sleep((long) i_14_);
				} catch (Exception exception) {
				}
			}
		} catch (Exception exception) {
		}
		aBoolean1320 = false;
	}

	private final void method18() {
		for (Class50_Sub2 class50_sub2 = (Class50_Sub2) aDeque_1261.method158(); class50_sub2 != null; class50_sub2 = (Class50_Sub2) aDeque_1261
			.method160(1)) {
			if (class50_sub2.anInt1390 == -1) {
				class50_sub2.anInt1395 = 0;
				method140((byte) -61, class50_sub2);
			} else {
				class50_sub2.method453();
			}
		}
	}

	private final void method19(String string) {
		System.out.println(string);
		try {
			getAppletContext().showDocument(
				new URL(getCodeBase(), ("loaderror_" + string + ".html")));
		} catch (Exception exception) {
			exception.printStackTrace();
		}
		for (;;) {
			try {
				Thread.sleep(1000L);
			} catch (Exception exception) {
			}
		}
	}

	private static final String method20(int i, int i_17_) {
		if (i_17_ >= 0) {
			throw new NullPointerException();
		}
		if (i < 100000) {
			return String.valueOf(i);
		}
		if (i < 10000000) {
			return String.valueOf(i / 1000) + "K";
		}
		return String.valueOf(i / 1000000) + "M";
	}

	public final void method8(int i) {
		totalPlayers = null;
		((Client) this).playerIndices = null;
		anIntArray974 = null;
		aPacketArray975 = null;
		((Client) this).anIntArray1295 = null;
		aGraphicsBuffer_906 = null;
		aGraphicsBuffer_907 = null;
		aGraphicsBuffer_908 = null;
		aGraphicsBuffer_909 = null;
		aIndexedSprite_880 = null;
		aIndexedSprite_881 = null;
		aIndexedSprite_882 = null;
		aIndexedSprite_883 = null;
		aIndexedSprite_884 = null;
		aIndexedSprite_983 = null;
		aIndexedSprite_984 = null;
		aIndexedSprite_985 = null;
		aIndexedSprite_986 = null;
		aIndexedSprite_987 = null;
		friendNames = null;
		friendNameForLong = null;
		friendNodeIds = null;
		aGraphicsBuffer_1108 = null;
		aGraphicsBuffer_1109 = null;
		aGraphicsBuffer_1110 = null;
		anIntArray1039 = null;
		anIntArray856 = null;
		aByteArrayArray838 = null;
		aByteArrayArray1232 = null;
		anIntArray857 = null;
		anIntArray858 = null;
		aGraphicsBuffer_1203 = null;
		aGraphicsBuffer_1204 = null;
		aGraphicsBuffer_1205 = null;
		aGraphicsBuffer_1206 = null;
		anIntArrayArray885 = null;
		anIntArrayArray1189 = null;
		anIntArray1123 = null;
		anIntArray1124 = null;
		aSprite_1192 = null;
		aSprite_1193 = null;
		aSprite_1194 = null;
		aSprite_1195 = null;
		aSprite_1196 = null;
		if (((Client) this).aClass7_1248 != null) {
			((Client) this).aClass7_1248.aBoolean131 = false;
		}
		((Client) this).aClass7_1248 = null;
		backbase1 = null;
		backbase2 = null;
		backhmid1 = null;
		aGraphicsBuffer_910 = null;
		aGraphicsBuffer_911 = null;
		aGraphicsBuffer_912 = null;
		aGraphicsBuffer_913 = null;
		aGraphicsBuffer_914 = null;
		anIntArrayArrayArray891 = null;
		aByteArrayArrayArray1125 = null;
		aClass22_1164 = null;
		aCollisionMapArray1260 = null;
		aSprite_1122 = null;
		aGraphicsBuffer_1201 = null;
		aGraphicsBuffer_1202 = null;
		aGraphicsBuffer_1198 = null;
		aGraphicsBuffer_1199 = null;
		aGraphicsBuffer_1200 = null;
		compass = null;
		hitmarks = null;
		headicons_pk = null;
		headicons_prayer = null;
		headicons_hint = null;
		aSpriteArray896 = null;
		method50(false);
		aPacket_964 = null;
		aPacket_929 = null;
		inputStream = null;
		aGraphicsBuffer_1156 = null;
		aGraphicsBuffer_1157 = null;
		aGraphicsBuffer_1158 = null;
		aGraphicsBuffer_1159 = null;
		invback = null;
		mapback = null;
		chatback = null;
		try {
			if (socket != null) {
				socket.method224();
			}
		} catch (Exception exception) {
		}
		socket = null;
		anIntArray1077 = null;
		anIntArray1078 = null;
		aSpriteArray1278 = null;
		totalNpcs = null;
		((Client) this).anIntArray1134 = null;
		aByteArray1245 = null;
		aPacket_1131 = null;
		mapscenes = null;
		mapfunctions = null;
		anIntArrayArray886 = null;
		sideicons = null;
		aDeque_1282 = null;
		aDeque_1210 = null;
		overlay_multiway = null;
		if (aClass32_Sub1_1291 != null) {
			aClass32_Sub1_1291.method339();
		}
		aClass32_Sub1_1291 = null;
		anIntArray979 = null;
		anIntArray980 = null;
		anIntArray981 = null;
		anIntArray982 = null;
		aStringArray1184 = null;
		aDequeArrayArrayArray1323 = null;
		i = 96 / i;
		aDeque_1261 = null;
		method141(28614);
		ObjectDefinition.method444();
		NpcDefinition.method369(false);
		ItemDefinition.method222(false);
		Interface.method202(false);
		Floor.floors = null;
		IdentityKit.appearances = null;
		Class4.aClass4Array103 = null;
		Sequence.sequences = null;
		SpotAnimation.spotAnims = null;
		SpotAnimation.aCache_566 = null;
		Varp.varps = null;
		aGraphicsBuffer_15 = null;
		Player.aCache_1761 = null;
		Renderer3D.method503(false);
		Class22.method240(false);
		Model.method584(false);
		Class21.method237();
		System.gc();
	}

	public final void method21(boolean bool) {
		if (!bool) {
			if (anInt28 == 1) {
				if (anInt29 >= 539 && anInt29 <= 573 && anInt30 >= 169 && anInt30 < 205
					&& anIntArray1081[0] != -1) {
					drawInventoryRequest = true;
					anInt1285 = 0;
					aBoolean950 = true;
				}
				if (anInt29 >= 569 && anInt29 <= 599 && anInt30 >= 168 && anInt30 < 205
					&& anIntArray1081[1] != -1) {
					drawInventoryRequest = true;
					anInt1285 = 1;
					aBoolean950 = true;
				}
				if (anInt29 >= 597 && anInt29 <= 627 && anInt30 >= 168 && anInt30 < 205
					&& anIntArray1081[2] != -1) {
					drawInventoryRequest = true;
					anInt1285 = 2;
					aBoolean950 = true;
				}
				if (anInt29 >= 625 && anInt29 <= 669 && anInt30 >= 168 && anInt30 < 203
					&& anIntArray1081[3] != -1) {
					drawInventoryRequest = true;
					anInt1285 = 3;
					aBoolean950 = true;
				}
				if (anInt29 >= 666 && anInt29 <= 696 && anInt30 >= 168 && anInt30 < 205
					&& anIntArray1081[4] != -1) {
					drawInventoryRequest = true;
					anInt1285 = 4;
					aBoolean950 = true;
				}
				if (anInt29 >= 694 && anInt29 <= 724 && anInt30 >= 168 && anInt30 < 205
					&& anIntArray1081[5] != -1) {
					drawInventoryRequest = true;
					anInt1285 = 5;
					aBoolean950 = true;
				}
				if (anInt29 >= 722 && anInt29 <= 756 && anInt30 >= 169 && anInt30 < 205
					&& anIntArray1081[6] != -1) {
					drawInventoryRequest = true;
					anInt1285 = 6;
					aBoolean950 = true;
				}
				if (anInt29 >= 540 && anInt29 <= 574 && anInt30 >= 466 && anInt30 < 502
					&& anIntArray1081[7] != -1) {
					drawInventoryRequest = true;
					anInt1285 = 7;
					aBoolean950 = true;
				}
				if (anInt29 >= 572 && anInt29 <= 602 && anInt30 >= 466 && anInt30 < 503
					&& anIntArray1081[8] != -1) {
					drawInventoryRequest = true;
					anInt1285 = 8;
					aBoolean950 = true;
				}
				if (anInt29 >= 599 && anInt29 <= 629 && anInt30 >= 466 && anInt30 < 503
					&& anIntArray1081[9] != -1) {
					drawInventoryRequest = true;
					anInt1285 = 9;
					aBoolean950 = true;
				}
				if (anInt29 >= 627 && anInt29 <= 671 && anInt30 >= 467 && anInt30 < 502
					&& anIntArray1081[10] != -1) {
					drawInventoryRequest = true;
					anInt1285 = 10;
					aBoolean950 = true;
				}
				if (anInt29 >= 669 && anInt29 <= 699 && anInt30 >= 466 && anInt30 < 503
					&& anIntArray1081[11] != -1) {
					drawInventoryRequest = true;
					anInt1285 = 11;
					aBoolean950 = true;
				}
				if (anInt29 >= 696 && anInt29 <= 726 && anInt30 >= 466 && anInt30 < 503
					&& anIntArray1081[12] != -1) {
					drawInventoryRequest = true;
					anInt1285 = 12;
					aBoolean950 = true;
				}
				if (anInt29 >= 724 && anInt29 <= 758 && anInt30 >= 466 && anInt30 < 502
					&& anIntArray1081[13] != -1) {
					drawInventoryRequest = true;
					anInt1285 = 13;
					aBoolean950 = true;
				}
			}
		}
	}

	public final void method22(int i) {
		i = 61 / i;
		do {
			try {
				int i_18_ = (((ObjectInstance) Client.myPlayer).anInt1610 + anInt853);
				int i_19_ = (((ObjectInstance) Client.myPlayer).anInt1611 + anInt1009);
				if (anInt1262 - i_18_ < -500 || anInt1262 - i_18_ > 500 || anInt1263 - i_19_ < -500
					|| anInt1263 - i_19_ > 500) {
					anInt1262 = i_18_;
					anInt1263 = i_19_;
				}
				if (anInt1262 != i_18_) {
					anInt1262 += (i_18_ - anInt1262) / 16;
				}
				if (anInt1263 != i_19_) {
					anInt1263 += (i_19_ - anInt1263) / 16;
				}
				if (anIntArray32[1] == 1) {
					Client client = this;
					int i_21_ = client.anInt1253;
					int i_22_ = (-24 - anInt1253) / 2;
					client.anInt1253 = i_22_ + i_21_;
				} else if (anIntArray32[2] == 1) {
					Client client = this;
					int i_24_ = client.anInt1253;
					int i_25_ = (24 - anInt1253) / 2;
					client.anInt1253 = i_25_ + i_24_;
				} else {
					anInt1253 /= 2;
				}
				if (anIntArray32[3] == 1) {
					Client client = this;
					int i_27_ = client.anInt1254;
					int i_28_ = (12 - anInt1254) / 2;
					client.anInt1254 = i_28_ + i_27_;
				} else if (anIntArray32[4] == 1) {
					Client client = this;
					int i_30_ = client.anInt1254;
					int i_31_ = (-12 - anInt1254) / 2;
					client.anInt1254 = i_31_ + i_30_;
				} else {
					anInt1254 /= 2;
				}
				anInt1252 = anInt1252 + anInt1253 / 2 & 0x7ff;
				anInt1251 += anInt1254 / 2;
				if (anInt1251 < 128) {
					anInt1251 = 128;
				}
				if (anInt1251 > 383) {
					anInt1251 = 383;
				}
				int i_32_ = anInt1262 >> 7;
				int i_33_ = anInt1263 >> 7;
				int i_34_ = method110(anInt1263, anInt1262, (byte) 9, anInt1091);
				int i_35_ = 0;
				if (i_32_ > 3 && i_33_ > 3 && i_32_ < 100 && i_33_ < 100) {
					for (int i_36_ = i_32_ - 4; i_36_ <= i_32_ + 4; i_36_++) {
						for (int i_37_ = i_33_ - 4; i_37_ <= i_33_ + 4; i_37_++) {
							int i_38_ = anInt1091;
							if (i_38_ < 3 && (aByteArrayArrayArray1125[1][i_36_][i_37_] & 0x2) == 2) {
								i_38_++;
							}
							int i_39_ = i_34_ - (anIntArrayArrayArray891[i_38_][i_36_][i_37_]);
							if (i_39_ > i_35_) {
								i_35_ = i_39_;
							}
						}
					}
				}
				int i_40_ = i_35_ * 192;
				if (i_40_ > 98048) {
					i_40_ = 98048;
				}
				if (i_40_ < 32768) {
					i_40_ = 32768;
				}
				if (i_40_ > anInt1289) {
					anInt1289 += (i_40_ - anInt1289) / 24;
				} else {
					if (i_40_ >= anInt1289) {
						break;
					}
					anInt1289 += (i_40_ - anInt1289) / 80;
				}
			} catch (Exception exception) {
				Signlink.reporterror("glfc_ex "
					+ (((ObjectInstance) Client.myPlayer).anInt1610) + ","
					+ (((ObjectInstance) Client.myPlayer).anInt1611) + "," + anInt1262
					+ "," + anInt1263 + "," + anInt889 + "," + anInt890 + "," + anInt1040 + ","
					+ anInt1041);
				throw new RuntimeException("eek");
			}
			break;
		} while (false);
	}

	public final boolean method23(Interface iComponent, int i) {
		i = 98 / i;
		int i_41_ = iComponent.anInt242;
		if (i_41_ >= 1 && i_41_ <= 200 || i_41_ >= 701 && i_41_ <= 900) {
			if (i_41_ >= 801) {
				i_41_ -= 701;
			} else if (i_41_ >= 701) {
				i_41_ -= 601;
			} else if (i_41_ >= 101) {
				i_41_ -= 101;
			} else {
				i_41_--;
			}
			aStringArray1184[anInt1183] = "Remove @whi@" + friendNames[i_41_];
			anIntArray981[anInt1183] = 775;
			anInt1183++;
			aStringArray1184[anInt1183] = "Message @whi@" + friendNames[i_41_];
			anIntArray981[anInt1183] = 984;
			anInt1183++;
			return true;
		}
		if (i_41_ >= 401 && i_41_ <= 500) {
			aStringArray1184[anInt1183] = "Remove @whi@" + iComponent.aString230;
			anIntArray981[anInt1183] = 859;
			anInt1183++;
			return true;
		}
		return false;
	}

	public final void method24(boolean bool, byte[] is, int i) {
		if (aBoolean1266) {
			Signlink.midifade = bool ? 1 : 0;
			Signlink.midisave(is, is.length);
			i = 71 / i;
		}
	}

	public final void method25(int i) {
		if (i != 0) {
			aPacket_964.putByte(186);
		}
		aBoolean1277 = true;
		for (int i_42_ = 0; i_42_ < 7; i_42_++) {
			anIntArray1326[i_42_] = -1;
			for (int i_43_ = 0; i_43_ < IdentityKit.anInt814; i_43_++) {
				if (!IdentityKit.appearances[i_43_].aBoolean821
					&& (IdentityKit.appearances[i_43_].anInt816 == i_42_ + (aBoolean1144 ? 0 : 7))) {
					anIntArray1326[i_42_] = i_43_;
					break;
				}
			}
		}
	}

	public final void method26(int i, int i_44_) {
		Deque deque = aDequeArrayArrayArray1323[anInt1091][i][i_44_];
		if (deque == null) {
			aClass22_1164.method262(anInt1091, i, i_44_);
		} else {
			int i_45_ = -99999999;
			Class50_Sub1_Sub4_Sub1 class50_sub1_sub4_sub1 = null;
			for (Class50_Sub1_Sub4_Sub1 class50_sub1_sub4_sub1_46_ = (Class50_Sub1_Sub4_Sub1) deque
				.method158(); class50_sub1_sub4_sub1_46_ != null; class50_sub1_sub4_sub1_46_ = (Class50_Sub1_Sub4_Sub1) deque
				.method160(1)) {
				ItemDefinition itemDefinition = ItemDefinition
					.method212(class50_sub1_sub4_sub1_46_.anInt1550);
				int i_47_ = itemDefinition.anInt345;
				if (itemDefinition.aBoolean371) {
					i_47_ *= class50_sub1_sub4_sub1_46_.anInt1552 + 1;
				}
				if (i_47_ > i_45_) {
					i_45_ = i_47_;
					class50_sub1_sub4_sub1 = class50_sub1_sub4_sub1_46_;
				}
			}
			deque.method156((byte) -57, class50_sub1_sub4_sub1);
			Class50_Sub1_Sub4_Sub1 class50_sub1_sub4_sub1_48_ = null;
			Class50_Sub1_Sub4_Sub1 class50_sub1_sub4_sub1_49_ = null;
			for (Class50_Sub1_Sub4_Sub1 class50_sub1_sub4_sub1_50_ = (Class50_Sub1_Sub4_Sub1) deque
				.method158(); class50_sub1_sub4_sub1_50_ != null; class50_sub1_sub4_sub1_50_ = (Class50_Sub1_Sub4_Sub1) deque
				.method160(1)) {
				if ((class50_sub1_sub4_sub1_50_.anInt1550 != class50_sub1_sub4_sub1.anInt1550)
					&& class50_sub1_sub4_sub1_48_ == null) {
					class50_sub1_sub4_sub1_48_ = class50_sub1_sub4_sub1_50_;
				}
				if ((class50_sub1_sub4_sub1_50_.anInt1550 != class50_sub1_sub4_sub1.anInt1550)
					&& (class50_sub1_sub4_sub1_50_.anInt1550 != class50_sub1_sub4_sub1_48_.anInt1550)
					&& class50_sub1_sub4_sub1_49_ == null) {
					class50_sub1_sub4_sub1_49_ = class50_sub1_sub4_sub1_50_;
				}
			}
			int i_51_ = i + (i_44_ << 7) + 1610612736;
			aClass22_1164.method248(method110(i_44_ * 128 + 64, i * 128 + 64, (byte) 9, anInt1091),
				anInt1091, class50_sub1_sub4_sub1, class50_sub1_sub4_sub1_48_, i_51_,
				class50_sub1_sub4_sub1_49_, 2, i_44_, i);
		}
	}

	public static final void method27(boolean bool) {
		Class22.aBoolean451 = false;
		Renderer3D.aBoolean1527 = false;
		Client.aBoolean926 = false;
		Class8.aBoolean169 = false;
		if (!bool) {
			Client.anInt1025 = 143;
		}
		ObjectDefinition.aBoolean772 = false;
	}

	public final void method28(byte i) {
		do {
			try {
				if (anInt1057 > 1) {
					anInt1057--;
				}
				if (anInt873 > 0) {
					anInt873--;
				}
				for (int i_52_ = 0; i_52_ < 5; i_52_++) {
					if (!parsePacket()) {
						break;
					}
				}
				if (aBoolean1137) {
					synchronized (((Client) this).aClass7_1248.anObject133) {
						if (Client.aBoolean962) {
							if (anInt28 != 0 || (((Client) this).aClass7_1248.anInt136 >= 40)) {
								aPacket_964.putOpcode(171);
								aPacket_964.putByte(0);
								int i_53_ = aPacket_964.offset;
								int i_54_ = 0;
								for (int i_55_ = 0; (i_55_ < ((Client) this).aClass7_1248.anInt136); i_55_++) {
									if ((i_53_ - aPacket_964.offset) >= 240) {
										break;
									}
									i_54_++;
									int i_56_ = (((Client) this).aClass7_1248.anIntArray132[i_55_]);
									if (i_56_ < 0) {
										i_56_ = 0;
									} else if (i_56_ > 502) {
										i_56_ = 502;
									}
									int i_57_ = (((Client) this).aClass7_1248.anIntArray137[i_55_]);
									if (i_57_ < 0) {
										i_57_ = 0;
									} else if (i_57_ > 764) {
										i_57_ = 764;
									}
									int i_58_ = i_56_ * 765 + i_57_;
									if ((((Client) this).aClass7_1248.anIntArray132[i_55_]) == -1
										&& (((Client) this).aClass7_1248.anIntArray137[i_55_]) == -1) {
										i_57_ = -1;
										i_56_ = -1;
										i_58_ = 524287;
									}
									if (i_57_ == ((Client) this).anInt1011
										&& (i_56_ == ((Client) this).anInt1012)) {
										if (((Client) this).anInt1299 < 2047) {
											((Client) this).anInt1299++;
										}
									} else {
										int i_59_ = (i_57_ - ((Client) this).anInt1011);
										((Client) this).anInt1011 = i_57_;
										int i_60_ = (i_56_ - ((Client) this).anInt1012);
										((Client) this).anInt1012 = i_56_;
										if (((Client) this).anInt1299 < 8 && i_59_ >= -32
											&& i_59_ <= 31 && i_60_ >= -32 && i_60_ <= 31) {
											i_59_ += 32;
											i_60_ += 32;
											aPacket_964.putShort((((Client) this).anInt1299 << 12)
												+ (i_59_ << 6) + i_60_);
											((Client) this).anInt1299 = 0;
										} else if (((Client) this).anInt1299 < 8) {
											aPacket_964
												.put24BitInt((((Client) this).anInt1299 << 19)
													+ 8388608 + i_58_);
											((Client) this).anInt1299 = 0;
										} else {
											aPacket_964.putInt((((Client) this).anInt1299 << 19)
												+ -1073741824 + i_58_);
											((Client) this).anInt1299 = 0;
										}
									}
								}
								aPacket_964.putSizeByte(aPacket_964.offset - i_53_);
								if (i_54_ >= ((Client) this).aClass7_1248.anInt136) {
									((Client) this).aClass7_1248.anInt136 = 0;
								} else {
									((Client) this).aClass7_1248.anInt136 -= i_54_;
									for (int i_61_ = 0; i_61_ < (((Client) this).aClass7_1248.anInt136); i_61_++) {
										((Client) this).aClass7_1248.anIntArray137[i_61_] = (((Client) this).aClass7_1248.anIntArray137[i_61_
											+ i_54_]);
										((Client) this).aClass7_1248.anIntArray132[i_61_] = (((Client) this).aClass7_1248.anIntArray132[i_61_
											+ i_54_]);
									}
								}
							}
						} else {
							((Client) this).aClass7_1248.anInt136 = 0;
						}
					}
					if (anInt28 != 0) {
						long l = (aLong31 - ((Client) this).aLong902) / 50L;
						if (l > 4095L) {
							l = 4095L;
						}
						((Client) this).aLong902 = aLong31;
						int i_62_ = anInt30;
						if (i_62_ < 0) {
							i_62_ = 0;
						} else if (i_62_ > 502) {
							i_62_ = 502;
						}
						int i_63_ = anInt29;
						if (i_63_ < 0) {
							i_63_ = 0;
						} else if (i_63_ > 764) {
							i_63_ = 764;
						}
						int i_64_ = i_62_ * 765 + i_63_;
						int i_65_ = 0;
						if (anInt28 == 2) {
							i_65_ = 1;
						}
						int i_66_ = (int) l;
						aPacket_964.putOpcode(19);
						aPacket_964.putInt((i_66_ << 20) + (i_65_ << 19) + i_64_);
					}
					if (anInt1264 > 0) {
						anInt1264--;
					}
					if (anIntArray32[1] == 1 || anIntArray32[2] == 1 || anIntArray32[3] == 1
						|| anIntArray32[4] == 1) {
						aBoolean1265 = true;
					}
					if (aBoolean1265 && anInt1264 <= 0) {
						anInt1264 = 20;
						aBoolean1265 = false;
						aPacket_964.putOpcode(140);
						aPacket_964.putLEShort_duplicate(anInt1251);
						aPacket_964.putLEShort_duplicate(anInt1252);
					}
					if (aBoolean19 == true && ((Client) this).aBoolean1275 == false) {
						((Client) this).aBoolean1275 = true;
						aPacket_964.putOpcode(187);
						aPacket_964.putByte(1);
					}
					if (aBoolean19 == false && ((Client) this).aBoolean1275 == true) {
						((Client) this).aBoolean1275 = false;
						aPacket_964.putOpcode(187);
						aPacket_964.putByte(0);
					}
					method143((byte) -40);
					method36(16220);
					method152(-23763);
					anInt871++;
					if (anInt871 > 750) {
						method59(1);
					}
					method100(0);
					method67(-37214);
					method85(0);
					anInt951++;
					if (anInt1023 != 0) {
						anInt1022 += 20;
						if (anInt1022 >= 400) {
							anInt1023 = 0;
						}
					}
					if (anInt1332 != 0) {
						anInt1329++;
						if (anInt1329 >= 15) {
							if (anInt1332 == 2) {
								drawInventoryRequest = true;
							}
							if (anInt1332 == 3) {
								aBoolean1240 = true;
							}
							anInt1332 = 0;
						}
					}
					if (anInt1113 != 0) {
						anInt1269++;
						if (anInt22 > anInt1114 + 5 || anInt22 < anInt1114 - 5
							|| anInt23 > anInt1115 + 5 || anInt23 < anInt1115 - 5) {
							aBoolean1155 = true;
						}
						if (anInt21 == 0) {
							if (anInt1113 == 2) {
								drawInventoryRequest = true;
							}
							if (anInt1113 == 3) {
								aBoolean1240 = true;
							}
							anInt1113 = 0;
							if (aBoolean1155 && anInt1269 >= 5) {
								anInt1064 = -1;
								method91(-521);
								if (anInt1064 == anInt1111 && anInt1063 != anInt1112) {
									Interface iComponent = Interface.method195(anInt1111);
									int i_67_ = 0;
									if (anInt955 == 1 && iComponent.anInt242 == 206) {
										i_67_ = 1;
									}
									if (iComponent.anIntArray269[anInt1063] <= 0) {
										i_67_ = 0;
									}
									if (iComponent.aBoolean217) {
										int i_68_ = anInt1112;
										int i_69_ = anInt1063;
										iComponent.anIntArray269[i_69_] = iComponent.anIntArray269[i_68_];
										iComponent.anIntArray224[i_69_] = iComponent.anIntArray224[i_68_];
										iComponent.anIntArray269[i_68_] = -1;
										iComponent.anIntArray224[i_68_] = 0;
									} else if (i_67_ == 1) {
										int i_70_ = anInt1112;
										int i_71_ = anInt1063;
										while (i_70_ != i_71_) {
											if (i_70_ > i_71_) {
												iComponent.method196(i_70_ - 1, -291, i_70_);
												i_70_--;
											} else if (i_70_ < i_71_) {
												iComponent.method196(i_70_ + 1, -291, i_70_);
												i_70_++;
											}
										}
									} else {
										iComponent.method196(anInt1063, -291, anInt1112);
									}
									aPacket_964.putOpcode(123);
									aPacket_964.putLEShortA(anInt1063);
									aPacket_964.putByteA(i_67_);
									aPacket_964.putShortA(anInt1111);
									aPacket_964.putLEShort_duplicate(anInt1112);
								}
							} else if ((anInt1300 == 1 || method126(anInt1183 - 1, aByte1161))
								&& anInt1183 > 2) {
								method108(811);
							} else if (anInt1183 > 0) {
								method120(anInt1183 - 1, 8);
							}
							anInt1329 = 10;
							anInt28 = 0;
						}
					}
					if (Class22.anInt485 != -1) {
						int i_72_ = Class22.anInt485;
						int i_73_ = Class22.anInt486;
						boolean bool = method35(true, false, i_73_,
							(((ObjectInstance) Client.myPlayer).anIntArray1587[0]), 0,
							0, 0, 0, i_72_, 0, 0,
							(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
						Class22.anInt485 = -1;
						if (bool) {
							anInt1020 = anInt29;
							anInt1021 = anInt30;
							anInt1023 = 1;
							anInt1022 = 0;
						}
					}
					if (anInt28 == 1 && aString1058 != null) {
						aString1058 = null;
						aBoolean1240 = true;
						anInt28 = 0;
					}
					method54(0);
					if (anInt1053 == -1) {
						method146((byte) 4);
						method21(false);
						method39(true);
					}
					if (anInt21 == 1 || anInt28 == 1) {
						anInt1094++;
					}
					if (anInt1284 != 0 || anInt1044 != 0 || anInt1129 != 0) {
						if (anInt893 < 100) {
							anInt893++;
							if (anInt893 == 100) {
								if (anInt1284 != 0) {
									aBoolean1240 = true;
								}
								if (anInt1044 != 0) {
									drawInventoryRequest = true;
								}
							}
						}
					} else if (anInt893 > 0) {
						anInt893--;
					}
					if (anInt1071 == 2) {
						method22(409);
					}
					if (anInt1071 == 2 && aBoolean1211) {
						method29(aBoolean959);
					}
					for (int i_74_ = 0; i_74_ < 5; i_74_++) {
						anIntArray1145[i_74_]++;
					}
					method30((byte) 2);
					anInt20++;
					if (anInt20 > 4500) {
						anInt873 = 250;
						anInt20 -= 500;
						aPacket_964.putOpcode(202);
					}
					anInt1118++;
					if (anInt1118 > 500) {
						anInt1118 = 0;
						int i_75_ = (int) (Math.random() * 8.0);
						if ((i_75_ & 0x1) == 1) {
							anInt853 += anInt854;
						}
						if ((i_75_ & 0x2) == 2) {
							anInt1009 += anInt1010;
						}
						if ((i_75_ & 0x4) == 4) {
							anInt1255 += anInt1256;
						}
					}
					if (anInt853 < -50) {
						anInt854 = 2;
					}
					if (anInt853 > 50) {
						anInt854 = -2;
					}
					if (anInt1009 < -55) {
						anInt1010 = 2;
					}
					if (anInt1009 > 55) {
						anInt1010 = -2;
					}
					if (anInt1255 < -40) {
						anInt1256 = 1;
					}
					if (anInt1255 > 40) {
						anInt1256 = -1;
					}
					anInt1045++;
					if (anInt1045 > 500) {
						anInt1045 = 0;
						int i_76_ = (int) (Math.random() * 8.0);
						if ((i_76_ & 0x1) == 1) {
							anInt916 += anInt917;
						}
						if ((i_76_ & 0x2) == 2) {
							anInt1233 += anInt1234;
						}
					}
					if (anInt916 < -60) {
						anInt917 = 2;
					}
					if (anInt916 > 60) {
						anInt917 = -2;
					}
					if (anInt1233 < -20) {
						anInt1234 = 1;
					}
					if (anInt1233 > 10) {
						anInt1234 = -1;
					}
					anInt872++;
					if (i != 4) {
						opcode = inputStream.getUByte();
					}
					if (anInt872 > 50) {
						aPacket_964.putOpcode(40);
					}
					try {
						if (socket == null || aPacket_964.offset <= 0) {
							break;
						}
						socket.method228(0, aPacket_964.offset, 0, aPacket_964.payload);
						aPacket_964.offset = 0;
						anInt872 = 0;
					} catch (IOException ioexception) {
						method59(1);
					} catch (Exception exception) {
						method124(true);
					}
					break;
				}
				break;
			} catch (RuntimeException runtimeexception) {
				Signlink.reporterror("71494, " + i + ", " + runtimeexception.toString());
				throw new RuntimeException();
			}
		} while (false);
	}

	public final void method29(boolean bool) {
		int i = anInt874 * 128 + 64;
		int i_77_ = anInt875 * 128 + 64;
		int i_78_ = method110(i_77_, i, (byte) 9, anInt1091) - anInt876;
		if (anInt1216 < i) {
			anInt1216 += anInt877 + (i - anInt1216) * anInt878 / 1000;
			if (anInt1216 > i) {
				anInt1216 = i;
			}
		}
		if (anInt1216 > i) {
			anInt1216 -= anInt877 + (anInt1216 - i) * anInt878 / 1000;
			if (anInt1216 < i) {
				anInt1216 = i;
			}
		}
		if (anInt1217 < i_78_) {
			anInt1217 += anInt877 + (i_78_ - anInt1217) * anInt878 / 1000;
			if (anInt1217 > i_78_) {
				anInt1217 = i_78_;
			}
		}
		if (anInt1217 > i_78_) {
			anInt1217 -= anInt877 + (anInt1217 - i_78_) * anInt878 / 1000;
			if (anInt1217 < i_78_) {
				anInt1217 = i_78_;
			}
		}
		if (anInt1218 < i_77_) {
			anInt1218 += anInt877 + (i_77_ - anInt1218) * anInt878 / 1000;
			if (anInt1218 > i_77_) {
				anInt1218 = i_77_;
			}
		}
		if (anInt1218 > i_77_) {
			anInt1218 -= anInt877 + (anInt1218 - i_77_) * anInt878 / 1000;
			if (anInt1218 < i_77_) {
				anInt1218 = i_77_;
			}
		}
		i = anInt993 * 128 + 64;
		i_77_ = anInt994 * 128 + 64;
		i_78_ = method110(i_77_, i, (byte) 9, anInt1091) - anInt995;
		int i_79_ = i - anInt1216;
		int i_80_ = i_78_ - anInt1217;
		int i_81_ = i_77_ - anInt1218;
		int i_82_ = (int) Math.sqrt((double) (i_79_ * i_79_ + i_81_ * i_81_));
		int i_83_ = ((int) (Math.atan2((double) i_80_, (double) i_82_) * 325.949) & 0x7ff);
		if (!bool) {
			for (int i_84_ = 1; i_84_ > 0; i_84_++) {
				/* empty */
			}
		}
		int i_85_ = ((int) (Math.atan2((double) i_79_, (double) i_81_) * -325.949) & 0x7ff);
		if (i_83_ < 128) {
			i_83_ = 128;
		}
		if (i_83_ > 383) {
			i_83_ = 383;
		}
		if (anInt1219 < i_83_) {
			anInt1219 += anInt996 + (i_83_ - anInt1219) * anInt997 / 1000;
			if (anInt1219 > i_83_) {
				anInt1219 = i_83_;
			}
		}
		if (anInt1219 > i_83_) {
			anInt1219 -= anInt996 + (anInt1219 - i_83_) * anInt997 / 1000;
			if (anInt1219 < i_83_) {
				anInt1219 = i_83_;
			}
		}
		int i_86_ = i_85_ - anInt1220;
		if (i_86_ > 1024) {
			i_86_ -= 2048;
		}
		if (i_86_ < -1024) {
			i_86_ += 2048;
		}
		if (i_86_ > 0) {
			anInt1220 += anInt996 + i_86_ * anInt997 / 1000;
			anInt1220 &= 0x7ff;
		}
		if (i_86_ < 0) {
			anInt1220 -= anInt996 + -i_86_ * anInt997 / 1000;
			anInt1220 &= 0x7ff;
		}
		int i_87_ = i_85_ - anInt1220;
		if (i_87_ > 1024) {
			i_87_ -= 2048;
		}
		if (i_87_ < -1024) {
			i_87_ += 2048;
		}
		if (i_87_ < 0 && i_86_ > 0 || i_87_ > 0 && i_86_ < 0) {
			anInt1220 = i_85_;
		}
	}

	public final void method30(byte i) {
		if (i == 2) {
			boolean bool = false;
		} else {
			return;
		}
		for (;;) {
			int i_88_ = this.method5();
			if (i_88_ == -1) {
				break;
			}
			if (anInt1169 != -1 && anInt1169 == anInt1231) {
				if (i_88_ == 8 && aString839.length() > 0) {
					aString839 = aString839.substring(0, aString839.length() - 1);
				}
				if ((i_88_ >= 97 && i_88_ <= 122 || i_88_ >= 65 && i_88_ <= 90 || i_88_ >= 48
					&& i_88_ <= 57 || i_88_ == 32)
					&& aString839.length() < 12) {
					aString839 += (char) i_88_;
				}
			} else if (aBoolean866) {
				if (i_88_ >= 32 && i_88_ <= 122 && aString1026.length() < 80) {
					aString1026 += (char) i_88_;
					aBoolean1240 = true;
				}
				if (i_88_ == 8 && aString1026.length() > 0) {
					aString1026 = aString1026.substring(0, aString1026.length() - 1);
					aBoolean1240 = true;
				}
				if (i_88_ == 13 || i_88_ == 10) {
					aBoolean866 = false;
					aBoolean1240 = true;
					if (anInt1221 == 1) {
						long l = TextUtil.method299(aString1026);
						method102(l, -45229);
					}
					if (anInt1221 == 2 && friendCount > 0) {
						long l = TextUtil.method299(aString1026);
						method53(l, 0);
					}
					if (anInt1221 == 3 && aString1026.length() > 0) {
						aPacket_964.putOpcode(227);
						aPacket_964.putByte(0);
						int i_89_ = aPacket_964.offset;
						aPacket_964.putLong(aLong1141);
						Class31.method321(aString1026, 569, aPacket_964);
						aPacket_964.putSizeByte(aPacket_964.offset - i_89_);
						aString1026 = Class31.method322((byte) 0, aString1026);
						aString1026 = Class45.method394((byte) 0, aString1026);
						sendMessage(TextUtil.method303(TextUtil.method300(aLong1141, 0)), aString1026, 6);
						if (anInt887 == 2) {
							anInt887 = 1;
							aBoolean1212 = true;
							aPacket_964.putOpcode(176);
							aPacket_964.putByte(anInt1006);
							aPacket_964.putByte(anInt887);
							aPacket_964.putByte(anInt1227);
						}
					}
					if (anInt1221 == 4 && anInt855 < 100) {
						long l = TextUtil.method299(aString1026);
						method90(anInt1154, l);
					}
					if (anInt1221 == 5 && anInt855 > 0) {
						long l = TextUtil.method299(aString1026);
						method97(325, l);
					}
				}
			} else if (anInt1244 == 1) {
				if (i_88_ >= 48 && i_88_ <= 57 && aString949.length() < 10) {
					aString949 += (char) i_88_;
					aBoolean1240 = true;
				}
				if (i_88_ == 8 && aString949.length() > 0) {
					aString949 = aString949.substring(0, aString949.length() - 1);
					aBoolean1240 = true;
				}
				if (i_88_ == 13 || i_88_ == 10) {
					if (aString949.length() > 0) {
						int i_90_ = 0;
						try {
							i_90_ = Integer.parseInt(aString949);
						} catch (Exception exception) {
							/* empty */
						}
						aPacket_964.putOpcode(75);
						aPacket_964.putInt(i_90_);
					}
					anInt1244 = 0;
					aBoolean1240 = true;
				}
			} else if (anInt1244 == 2) {
				if (i_88_ >= 32 && i_88_ <= 122 && aString949.length() < 12) {
					aString949 += (char) i_88_;
					aBoolean1240 = true;
				}
				if (i_88_ == 8 && aString949.length() > 0) {
					aString949 = aString949.substring(0, aString949.length() - 1);
					aBoolean1240 = true;
				}
				if (i_88_ == 13 || i_88_ == 10) {
					if (aString949.length() > 0) {
						aPacket_964.putOpcode(206);
						aPacket_964.putLong(TextUtil.method299(aString949));
					}
					anInt1244 = 0;
					aBoolean1240 = true;
				}
			} else if (anInt1244 == 3) {
				if (i_88_ >= 32 && i_88_ <= 122 && aString949.length() < 40) {
					aString949 += (char) i_88_;
					aBoolean1240 = true;
				}
				if (i_88_ == 8 && aString949.length() > 0) {
					aString949 = aString949.substring(0, aString949.length() - 1);
					aBoolean1240 = true;
				}
			} else if (anInt988 == -1 && anInt1053 == -1) {
				if (i_88_ >= 32 && i_88_ <= 122 && aString1104.length() < 80) {
					aString1104 += (char) i_88_;
					aBoolean1240 = true;
				}
				if (i_88_ == 8 && aString1104.length() > 0) {
					aString1104 = aString1104.substring(0, aString1104.length() - 1);
					aBoolean1240 = true;
				}
				if ((i_88_ == 13 || i_88_ == 10) && aString1104.length() > 0) {
					if (anInt867 == 2) {
						if (aString1104.equals("::clientdrop")) {
							method59(1);
						}
						if (aString1104.equals("::lag")) {
							method138(false);
						}
						if (aString1104.equals("::prefetchmusic")) {
							for (int i_91_ = 0; (i_91_ < aClass32_Sub1_1291.method340(2, -31140)); i_91_++) {
								aClass32_Sub1_1291.method327(-44, 2, (byte) 1, i_91_);
							}
						}
						if (aString1104.equals("::fpson")) {
							Client.aBoolean868 = true;
						}
						if (aString1104.equals("::fpsoff")) {
							Client.aBoolean868 = false;
						}
						if (aString1104.equals("::noclip")) {
							for (int i_92_ = 0; i_92_ < 4; i_92_++) {
								for (int i_93_ = 1; i_93_ < 103; i_93_++) {
									for (int i_94_ = 1; i_94_ < 103; i_94_++) {
										aCollisionMapArray1260[i_92_].anIntArrayArray757[i_93_][i_94_] = 0;
									}
								}
							}
						}
					}
					if (aString1104.startsWith("::")) {
						aPacket_964.putOpcode(56);
						aPacket_964.putByte(aString1104.length() - 1);
						aPacket_964.putString(aString1104.substring(2));
					} else {
						String string = aString1104.toLowerCase();
						int i_95_ = 0;
						if (string.startsWith("yellow:")) {
							i_95_ = 0;
							aString1104 = aString1104.substring(7);
						} else if (string.startsWith("red:")) {
							i_95_ = 1;
							aString1104 = aString1104.substring(4);
						} else if (string.startsWith("green:")) {
							i_95_ = 2;
							aString1104 = aString1104.substring(6);
						} else if (string.startsWith("cyan:")) {
							i_95_ = 3;
							aString1104 = aString1104.substring(5);
						} else if (string.startsWith("purple:")) {
							i_95_ = 4;
							aString1104 = aString1104.substring(7);
						} else if (string.startsWith("white:")) {
							i_95_ = 5;
							aString1104 = aString1104.substring(6);
						} else if (string.startsWith("flash1:")) {
							i_95_ = 6;
							aString1104 = aString1104.substring(7);
						} else if (string.startsWith("flash2:")) {
							i_95_ = 7;
							aString1104 = aString1104.substring(7);
						} else if (string.startsWith("flash3:")) {
							i_95_ = 8;
							aString1104 = aString1104.substring(7);
						} else if (string.startsWith("glow1:")) {
							i_95_ = 9;
							aString1104 = aString1104.substring(6);
						} else if (string.startsWith("glow2:")) {
							i_95_ = 10;
							aString1104 = aString1104.substring(6);
						} else if (string.startsWith("glow3:")) {
							i_95_ = 11;
							aString1104 = aString1104.substring(6);
						}
						string = aString1104.toLowerCase();
						int i_96_ = 0;
						if (string.startsWith("wave:")) {
							i_96_ = 1;
							aString1104 = aString1104.substring(5);
						} else if (string.startsWith("wave2:")) {
							i_96_ = 2;
							aString1104 = aString1104.substring(6);
						} else if (string.startsWith("shake:")) {
							i_96_ = 3;
							aString1104 = aString1104.substring(6);
						} else if (string.startsWith("scroll:")) {
							i_96_ = 4;
							aString1104 = aString1104.substring(7);
						} else if (string.startsWith("slide:")) {
							i_96_ = 5;
							aString1104 = aString1104.substring(6);
						}
						aPacket_964.putOpcode(49);
						aPacket_964.putByte(0);
						int i_97_ = aPacket_964.offset;
						aPacket_964.putByteC(i_95_);
						aPacket_964.putByteA(i_96_);
						aPacket_1131.offset = 0;
						Class31.method321(aString1104, 569, aPacket_1131);
						aPacket_964.putBytes(aPacket_1131.payload, aPacket_1131.offset, 0);
						aPacket_964.putSizeByte(aPacket_964.offset - i_97_);
						aString1104 = Class31.method322((byte) 0, aString1104);
						aString1104 = Class45.method394((byte) 0, aString1104);
						((ObjectInstance) Client.myPlayer).aString1580 = aString1104;
						((ObjectInstance) Client.myPlayer).anInt1583 = i_95_;
						((ObjectInstance) Client.myPlayer).anInt1593 = i_96_;
						((ObjectInstance) Client.myPlayer).anInt1582 = 150;
						if (anInt867 == 2) {
							sendMessage(("@cr2@" + (((Player) Client.myPlayer).aString1751)),
 (((ObjectInstance) Client.myPlayer).aString1580), 2);
						} else if (anInt867 == 1) {
							sendMessage(("@cr1@" + (((Player) Client.myPlayer).aString1751)),
 (((ObjectInstance) Client.myPlayer).aString1580), 2);
						} else {
							sendMessage((((Player) Client.myPlayer).aString1751), (((ObjectInstance) Client.myPlayer).aString1580), 2);
						}
						if (anInt1006 == 2) {
							anInt1006 = 3;
							aBoolean1212 = true;
							aPacket_964.putOpcode(176);
							aPacket_964.putByte(anInt1006);
							aPacket_964.putByte(anInt887);
							aPacket_964.putByte(anInt1227);
						}
					}
					aString1104 = "";
					aBoolean1240 = true;
				}
			}
		}
	}

	public final DataInputStream method31(String string) throws IOException {
		if (!aBoolean900) {
			if (Signlink.mainapp != null) {
				return Signlink.openurl(string);
			}
			return new DataInputStream(new URL(getCodeBase(), string).openStream());
		}
		if (aSocket1224 != null) {
			try {
				aSocket1224.close();
			} catch (Exception exception) {
				/* empty */
			}
			aSocket1224 = null;
		}
		aSocket1224 = method32(43595);
		aSocket1224.setSoTimeout(10000);
		InputStream inputstream = aSocket1224.getInputStream();
		OutputStream outputstream = aSocket1224.getOutputStream();
		outputstream.write(("JAGGRAB /" + string + "\n\n").getBytes());
		return new DataInputStream(inputstream);
	}

	public final java.net.Socket method32(int i) throws IOException {
		if (Signlink.mainapp != null) {
			return Signlink.opensocket(i);
		}
		return new java.net.Socket(InetAddress.getByName(getCodeBase().getHost()), i);
	}

	public final boolean parsePacket() {
		try {
			if (socket == null) {
				return false;
			}
			try {
				int i_99_ = socket.method226();
				if (i_99_ == 0) {
					return false;
				}
				if (opcode == -1) {
					socket.method227((inputStream.payload), 0, 1);
					opcode = inputStream.payload[0] & 0xff;
					if (cryption != null) {
						opcode = opcode - cryption.getNextKey() & 0xff;
					}
					packetSize = SizeConstants.packetSizes[opcode];
					i_99_--;
				}
				if (packetSize == -1) {
					if (i_99_ > 0) {
						socket.method227((inputStream.payload), 0, 1);
						packetSize = inputStream.payload[0] & 0xff;
						i_99_--;
					} else {
						return false;
					}
				}
				if (packetSize == -2) {
					if (i_99_ > 1) {
						socket.method227((inputStream.payload), 0, 2);
						inputStream.offset = 0;
						packetSize = inputStream.getUShort();
						i_99_ -= 2;
					} else {
						return false;
					}
				}
				if (i_99_ < packetSize) {
					return false;
				}
				inputStream.offset = 0;
				socket.method227(inputStream.payload, 0, packetSize);
				anInt871 = 0;
				anInt905 = anInt904;
				anInt904 = anInt903;
				anInt903 = opcode;
				if (opcode == 166) {
					int i_100_ = inputStream.getLEShort();
					int i_101_ = inputStream.getLEShort();
					int i_102_ = inputStream.getUShort();
					Interface iComponent = Interface.method195(i_102_);
					iComponent.anInt228 = i_101_;
					iComponent.anInt259 = i_100_;
					opcode = -1;
					return true;
				}
				if (opcode == 186) {
					int i_103_ = inputStream.getULEShortA1();
					int i_104_ = inputStream.getULEShortA2();
					int i_105_ = inputStream.getULEShortA1();
					int i_106_ = inputStream.getULEShort();
					Interface.method195(i_104_).anInt252 = i_103_;
					Interface.method195(i_104_).anInt253 = i_106_;
					Interface.method195(i_104_).anInt251 = i_105_;
					opcode = -1;
					return true;
				}
				if (opcode == 216) {
					int i_107_ = inputStream.getULEShortA2();
					int i_108_ = inputStream.getULEShortA2();
					Interface.method195(i_108_).anInt283 = 1;
					Interface.method195(i_108_).anInt284 = i_107_;
					opcode = -1;
					return true;
				}
				if (opcode == 26) {
					int i_109_ = inputStream.getUShort();
					int i_110_ = inputStream.getUByte();
					int i_111_ = inputStream.getUShort();
					if (i_111_ == 65535) {
						if (anInt1035 < 50) {
							anIntArray1090[anInt1035] = (short) i_109_;
							anIntArray1321[anInt1035] = i_110_;
							anIntArray1259[anInt1035] = 0;
							anInt1035++;
						}
					} else if (aBoolean1301 && !Client.aBoolean926 && anInt1035 < 50) {
						anIntArray1090[anInt1035] = i_109_;
						anIntArray1321[anInt1035] = i_110_;
						anIntArray1259[anInt1035] = i_111_ + Class38.anIntArray669[i_109_];
						anInt1035++;
					}
					opcode = -1;
					return true;
				}
				if (opcode == 182) {
					int i_112_ = inputStream.getULEShortA1();
					int i_113_ = inputStream.getByteS();
					anIntArray1005[i_112_] = i_113_;
					if (anIntArray1039[i_112_] != i_113_) {
						anIntArray1039[i_112_] = i_113_;
						method105(0, i_112_);
						drawInventoryRequest = true;
						if (anInt1191 != -1) {
							aBoolean1240 = true;
						}
					}
					opcode = -1;
					return true;
				}
				if (opcode == 13) {
					for (int i_114_ = 0; i_114_ < totalPlayers.length; i_114_++) {
						if (totalPlayers[i_114_] != null) {
							((ObjectInstance) totalPlayers[i_114_]).anInt1624 = -1;
						}
					}
					for (int i_115_ = 0; i_115_ < totalNpcs.length; i_115_++) {
						if (totalNpcs[i_115_] != null) {
							((ObjectInstance) totalNpcs[i_115_]).anInt1624 = -1;
						}
					}
					opcode = -1;
					return true;
				}
				if (opcode == 156) {
					anInt1050 = inputStream.getUByte();
					opcode = -1;
					return true;
				}
				if (opcode == 162) {
					int i_116_ = inputStream.getULEShortA1();
					int i_117_ = inputStream.getULEShort();
					Interface.method195(i_117_).anInt283 = 2;
					Interface.method195(i_117_).anInt284 = i_116_;
					opcode = -1;
					return true;
				}
				if (opcode == 109) {
					int i_118_ = inputStream.getUShort();
					method112((byte) 36, i_118_);
					if (anInt1089 != -1) {
						method44(Client.aBoolean1190, anInt1089);
						anInt1089 = -1;
						drawInventoryRequest = true;
						aBoolean950 = true;
					}
					if (anInt1053 != -1) {
						method44(Client.aBoolean1190, anInt1053);
						anInt1053 = -1;
						aBoolean1046 = true;
					}
					if (anInt960 != -1) {
						method44(Client.aBoolean1190, anInt960);
						anInt960 = -1;
					}
					if (anInt1169 != -1) {
						method44(Client.aBoolean1190, anInt1169);
						anInt1169 = -1;
					}
					if (anInt988 != i_118_) {
						method44(Client.aBoolean1190, anInt988);
						anInt988 = i_118_;
					}
					aBoolean1239 = false;
					aBoolean1240 = true;
					opcode = -1;
					return true;
				}
				if (opcode == 220) {
					int i_119_ = inputStream.getULEShortA2();
					if (i_119_ == 65535) {
						i_119_ = -1;
					}
					if (i_119_ != anInt1327 && aBoolean1266 && !Client.aBoolean926
						&& anInt1128 == 0) {
						anInt1270 = i_119_;
						aBoolean1271 = true;
						aClass32_Sub1_1291.method329(2, anInt1270);
					}
					anInt1327 = i_119_;
					opcode = -1;
					return true;
				}
				if (opcode == 249) {
					int i_120_ = inputStream.getULEShort();
					int i_121_ = inputStream.get24BitInt2();
					if (aBoolean1266 && !Client.aBoolean926) {
						anInt1270 = i_120_;
						aBoolean1271 = false;
						aClass32_Sub1_1291.method329(2, anInt1270);
						anInt1128 = i_121_;
					}
					opcode = -1;
					return true;
				}
				if (opcode == 158) {
					int i_122_ = inputStream.getLEShort();
					if (i_122_ != anInt1191) {
						method44(Client.aBoolean1190, anInt1191);
						anInt1191 = i_122_;
					}
					aBoolean1240 = true;
					opcode = -1;
					return true;
				}
				if (opcode == 218) {
					int i_123_ = inputStream.getUShort();
					int i_124_ = inputStream.getULEShortA1();
					int i_125_ = i_124_ >> 10 & 0x1f;
					int i_126_ = i_124_ >> 5 & 0x1f;
					int i_127_ = i_124_ & 0x1f;
					Interface.method195(i_123_).anInt240 = (i_125_ << 19) + (i_126_ << 11)
						+ (i_127_ << 3);
					opcode = -1;
					return true;
				}
				if (opcode == 157) {
					int i_128_ = inputStream.getUByteC();
					String string = inputStream.getString();
					int i_129_ = inputStream.getUByte();
					if (i_128_ >= 1 && i_128_ <= 5) {
						if (string.equalsIgnoreCase("null")) {
							string = null;
						}
						aStringArray1069[i_128_ - 1] = string;
						aBooleanArray1070[i_128_ - 1] = i_129_ == 0;
					}
					opcode = -1;
					return true;
				}
				if (opcode == 6) {
					aBoolean866 = false;
					anInt1244 = 2;
					aString949 = "";
					aBoolean1240 = true;
					opcode = -1;
					return true;
				}
				if (opcode == 201) {
					anInt1006 = inputStream.getUByte();
					anInt887 = inputStream.getUByte();
					anInt1227 = inputStream.getUByte();
					aBoolean1212 = true;
					aBoolean1240 = true;
					opcode = -1;
					return true;
				}
				if (opcode == 199) {
					anInt1197 = inputStream.getUByte();
					if (anInt1197 == 1) {
						anInt1226 = inputStream.getUShort();
					}
					if (anInt1197 >= 2 && anInt1197 <= 6) {
						if (anInt1197 == 2) {
							anInt847 = 64;
							anInt848 = 64;
						}
						if (anInt1197 == 3) {
							anInt847 = 0;
							anInt848 = 64;
						}
						if (anInt1197 == 4) {
							anInt847 = 128;
							anInt848 = 64;
						}
						if (anInt1197 == 5) {
							anInt847 = 64;
							anInt848 = 0;
						}
						if (anInt1197 == 6) {
							anInt847 = 64;
							anInt848 = 128;
						}
						anInt1197 = 2;
						anInt844 = inputStream.getUShort();
						anInt845 = inputStream.getUShort();
						anInt846 = inputStream.getUByte();
					}
					if (anInt1197 == 10) {
						anInt1151 = inputStream.getUShort();
					}
					opcode = -1;
					return true;
				}
				if (opcode == 167) {
					aBoolean1211 = true;
					anInt993 = inputStream.getUByte();
					anInt994 = inputStream.getUByte();
					anInt995 = inputStream.getUShort();
					anInt996 = inputStream.getUByte();
					anInt997 = inputStream.getUByte();
					if (anInt997 >= 100) {
						int i_130_ = anInt993 * 128 + 64;
						int i_131_ = anInt994 * 128 + 64;
						int i_132_ = (method110(i_131_, i_130_, (byte) 9, anInt1091) - anInt995);
						int i_133_ = i_130_ - anInt1216;
						int i_134_ = i_132_ - anInt1217;
						int i_135_ = i_131_ - anInt1218;
						int i_136_ = (int) Math.sqrt((double) (i_133_ * i_133_ + i_135_ * i_135_));
						anInt1219 = (int) (Math.atan2((double) i_134_, (double) i_136_) * 325.949) & 0x7ff;
						anInt1220 = (int) (Math.atan2((double) i_133_, (double) i_135_) * -325.949) & 0x7ff;
						if (anInt1219 < 128) {
							anInt1219 = 128;
						}
						if (anInt1219 > 383) {
							anInt1219 = 383;
						}
					}
					opcode = -1;
					return true;
				}
				if (opcode == 5) {
					method124(true);
					opcode = -1;
					return false;
				}
				if (opcode == 115) {
					int i_137_ = inputStream.getInt1();
					int i_138_ = inputStream.getULEShort();
					anIntArray1005[i_138_] = i_137_;
					if (anIntArray1039[i_138_] != i_137_) {
						anIntArray1039[i_138_] = i_137_;
						method105(0, i_138_);
						drawInventoryRequest = true;
						if (anInt1191 != -1) {
							aBoolean1240 = true;
						}
					}
					opcode = -1;
					return true;
				}
				if (opcode == 29) {
					if (anInt1089 != -1) {
						method44(Client.aBoolean1190, anInt1089);
						anInt1089 = -1;
						drawInventoryRequest = true;
						aBoolean950 = true;
					}
					if (anInt988 != -1) {
						method44(Client.aBoolean1190, anInt988);
						anInt988 = -1;
						aBoolean1240 = true;
					}
					if (anInt1053 != -1) {
						method44(Client.aBoolean1190, anInt1053);
						anInt1053 = -1;
						aBoolean1046 = true;
					}
					if (anInt960 != -1) {
						method44(Client.aBoolean1190, anInt960);
						anInt960 = -1;
					}
					if (anInt1169 != -1) {
						method44(Client.aBoolean1190, anInt1169);
						anInt1169 = -1;
					}
					if (anInt1244 != 0) {
						anInt1244 = 0;
						aBoolean1240 = true;
					}
					aBoolean1239 = false;
					opcode = -1;
					return true;
				}
				if (opcode == 76) {
					anInt1083 = inputStream.getULEShort();
					anInt1075 = inputStream.getULEShortA2();
					inputStream.getUShort();
					anInt1208 = inputStream.getUShort();
					anInt1170 = inputStream.getULEShort();
					anInt1273 = inputStream.getULEShortA1();
					anInt1215 = inputStream.getULEShortA1();
					anInt992 = inputStream.getUShort();
					anInt1241 = inputStream.getLEInt();
					anInt1034 = inputStream.getULEShortA2();
					inputStream.getUByteA();
					Signlink.dnslookup(TextUtil.method302(anInt1241, -826));
					opcode = -1;
					return true;
				}
				if (opcode == 63) {
					String string = inputStream.getString();
					if (string.endsWith(":tradereq:")) {
						String name = string.substring(0, string.indexOf(":"));
						long l = TextUtil.method299(name);
						boolean bool = false;
						for (int i_140_ = 0; i_140_ < anInt855; i_140_++) {
							if (aLongArray1073[i_140_] == l) {
								bool = true;
								break;
							}
						}
						if (!bool && anInt1246 == 0) {
							sendMessage(name, "wishes to trade with you.", 4);
						}
					} else if (string.endsWith(":duelreq:")) {
						String name = string.substring(0, string.indexOf(":"));
						long l = TextUtil.method299(name);
						boolean bool = false;
						for (int i_142_ = 0; i_142_ < anInt855; i_142_++) {
							if (aLongArray1073[i_142_] == l) {
								bool = true;
								break;
							}
						}
						if (!bool && anInt1246 == 0) {
							sendMessage(name, "wishes to duel with you.", 8);
						}
					} else if (string.endsWith(":chalreq:")) {
						String req = string.substring(0, string.indexOf(":"));
						long l = TextUtil.method299(req);
						boolean bool = false;
						for (int i_144_ = 0; i_144_ < anInt855; i_144_++) {
							if (aLongArray1073[i_144_] == l) {
								bool = true;
								break;
							}
						}
						if (!bool && anInt1246 == 0) {
							String string_145_ = string.substring(string.indexOf(":") + 1,
								string.length() - 9);
							sendMessage(req, string_145_, 8);
						}
					} else {
						sendMessage("", string, 0);
					}
					opcode = -1;
					return true;
				}
				if (opcode == 50) {
					int i_146_ = inputStream.getShort();
					if (i_146_ >= 0) {
						method112((byte) 36, i_146_);
					}
					if (i_146_ != anInt1279) {
						method44(Client.aBoolean1190, anInt1279);
						anInt1279 = i_146_;
					}
					opcode = -1;
					return true;
				}
				if (opcode == 82) {
					boolean bool = inputStream.getUByte() == 1;
					int i_147_ = inputStream.getUShort();
					Interface.method195(i_147_).aBoolean219 = bool;
					opcode = -1;
					return true;
				}
				if (opcode == 174) {
					if (anInt1285 == 12) {
						drawInventoryRequest = true;
					}
					anInt1030 = inputStream.getShort();
					opcode = -1;
					return true;
				}
				if (opcode == 233) {
					anInt1319 = inputStream.getUByte();
					opcode = -1;
					return true;
				}
				if (opcode == 61) {
					anInt1120 = 0;
					opcode = -1;
					return true;
				}
				if (opcode == 128) {
					int i_148_ = inputStream.getULEShortA1();
					int i_149_ = inputStream.getULEShortA2();
					if (anInt988 != -1) {
						method44(Client.aBoolean1190, anInt988);
						anInt988 = -1;
						aBoolean1240 = true;
					}
					if (anInt1053 != -1) {
						method44(Client.aBoolean1190, anInt1053);
						anInt1053 = -1;
						aBoolean1046 = true;
					}
					if (anInt960 != -1) {
						method44(Client.aBoolean1190, anInt960);
						anInt960 = -1;
					}
					if (anInt1169 != i_148_) {
						method44(Client.aBoolean1190, anInt1169);
						anInt1169 = i_148_;
					}
					if (anInt1089 != i_149_) {
						method44(Client.aBoolean1190, anInt1089);
						anInt1089 = i_149_;
					}
					if (anInt1244 != 0) {
						anInt1244 = 0;
						aBoolean1240 = true;
					}
					drawInventoryRequest = true;
					aBoolean950 = true;
					aBoolean1239 = false;
					opcode = -1;
					return true;
				}
				if (opcode == 67) {
					int i_150_ = inputStream.getUByte();
					int i_151_ = inputStream.getUByte();
					int i_152_ = inputStream.getUByte();
					int i_153_ = inputStream.getUByte();
					aBooleanArray927[i_150_] = true;
					anIntArray1105[i_150_] = i_151_;
					anIntArray852[i_150_] = i_152_;
					anIntArray991[i_150_] = i_153_;
					anIntArray1145[i_150_] = 0;
					opcode = -1;
					return true;
				}
				if (opcode == 134) {
					drawInventoryRequest = true;
					int i_154_ = inputStream.getUShort();
					Interface iComponent = Interface.method195(i_154_);
					while (inputStream.offset < packetSize) {
						int i_155_ = inputStream.getSmart();
						int i_156_ = inputStream.getUShort();
						int i_157_ = inputStream.getUByte();
						if (i_157_ == 255) {
							i_157_ = inputStream.getInt();
						}
						if (i_155_ >= 0 && i_155_ < iComponent.anIntArray269.length) {
							iComponent.anIntArray269[i_155_] = i_156_;
							iComponent.anIntArray224[i_155_] = i_157_;
						}
					}
					opcode = -1;
					return true;
				}
				if (opcode == 78) {
					long l = inputStream.getLong();
					int nodeId = inputStream.getUByte();
					String name = TextUtil.method303(TextUtil.method300(l, 0));
					for (int i_159_ = 0; i_159_ < friendCount; i_159_++) {
						if (l == friendNameForLong[i_159_]) {
							if (friendNodeIds[i_159_] != nodeId) {
								friendNodeIds[i_159_] = nodeId;
								drawInventoryRequest = true;
								if (nodeId > 0) {
									sendMessage("", name + " has logged in.", 5);
								}
								if (nodeId == 0) {
									sendMessage("", name + " has logged out.", 5);
								}
							}
							name = null;
							break;
						}
					}
					if (name != null && friendCount < 200) {
						friendNameForLong[friendCount] = l;
						friendNames[friendCount] = name;
						friendNodeIds[friendCount] = nodeId;
						friendCount++;
						drawInventoryRequest = true;
					}
					boolean bool = false;
					while (!bool) {
						bool = true;
						for (int id = 0; id < friendCount - 1; id++) {
							if ((friendNodeIds[id] != Client.anInt923 && friendNodeIds[id + 1] == Client.anInt923)
								|| (friendNodeIds[id] == 0 && friendNodeIds[id + 1] != 0)) {
								int nodeId_ = friendNodeIds[id];
								friendNodeIds[id] = friendNodeIds[id + 1];
								friendNodeIds[id + 1] = nodeId_;
								String name_ = friendNames[id];
								friendNames[id] = friendNames[id + 1];
								friendNames[id + 1] = name_;
								long l_ = friendNameForLong[id];
								friendNameForLong[id] = friendNameForLong[id + 1];
								friendNameForLong[id + 1] = l_;
								drawInventoryRequest = true;
								bool = false;
							}
						}
					}
					opcode = -1;
					return true;
				}
				if (opcode == 58) {
					aBoolean866 = false;
					anInt1244 = 1;
					aString949 = "";
					aBoolean1240 = true;
					opcode = -1;
					return true;
				}
				if (opcode == 252) {
					anInt1285 = inputStream.getUByteC();
					drawInventoryRequest = true;
					aBoolean950 = true;
					opcode = -1;
					return true;
				}
				if (opcode == 40) {
					anInt990 = inputStream.getUByteS();
					anInt989 = inputStream.getUByteC();
					for (int i_164_ = anInt989; i_164_ < anInt989 + 8; i_164_++) {
						for (int i_165_ = anInt990; i_165_ < anInt990 + 8; i_165_++) {
							if ((aDequeArrayArrayArray1323[anInt1091][i_164_][i_165_]) != null) {
								aDequeArrayArrayArray1323[anInt1091][i_164_][i_165_] = null;
								method26(i_164_, i_165_);
							}
						}
					}
					for (Class50_Sub2 class50_sub2 = (Class50_Sub2) aDeque_1261.method158(); class50_sub2 != null; class50_sub2 = (Class50_Sub2) aDeque_1261
						.method160(1)) {
						if (class50_sub2.anInt1393 >= anInt989
							&& class50_sub2.anInt1393 < anInt989 + 8
							&& class50_sub2.anInt1394 >= anInt990
							&& class50_sub2.anInt1394 < anInt990 + 8
							&& class50_sub2.anInt1391 == anInt1091) {
							class50_sub2.anInt1390 = 0;
						}
					}
					opcode = -1;
					return true;
				}
				if (opcode == 255) {
					int i_166_ = inputStream.getULEShortA2();
					Interface.method195(i_166_).anInt283 = 3;
					if (((Player) Client.myPlayer).aNpcDefinition_1757 == null) {
						Interface.method195(i_166_).anInt284 = (((((Player) Client.myPlayer).anIntArray1760[0]) << 25)
							+ ((((Player) Client.myPlayer).anIntArray1760[4]) << 20)
							+ ((((Player) Client.myPlayer).anIntArray1752[0]) << 15)
							+ ((((Player) Client.myPlayer).anIntArray1752[8]) << 10)
							+ ((((Player) Client.myPlayer).anIntArray1752[11]) << 5) + (((Player) Client.myPlayer).anIntArray1752[1]));
					} else {
						Interface.method195(i_166_).anInt284 = (int) (305419896L + (((Player) Client.myPlayer).aNpcDefinition_1757.aLong628));
					}
					opcode = -1;
					return true;
				}
				if (opcode == 135) {
					long l = inputStream.getLong();
					int i_167_ = inputStream.getInt();
					int rights = inputStream.getUByte();
					boolean bool = false;
					for (int i_169_ = 0; i_169_ < 100; i_169_++) {
						if (anIntArray1258[i_169_] == i_167_) {
							bool = true;
							break;
						}
					}
					if (rights <= 1) {
						for (int i_170_ = 0; i_170_ < anInt855; i_170_++) {
							if (aLongArray1073[i_170_] == l) {
								bool = true;
								break;
							}
						}
					}
					if (!bool && anInt1246 == 0) {
						try {
							anIntArray1258[anInt1152] = i_167_;
							anInt1152 = (anInt1152 + 1) % 100;
							String name = Class31.method320(0, inputStream, packetSize - 13);
							if (rights != 3) {
								name = Class45.method394((byte) 0, name);
							}
							if (rights == 2 || rights == 3) {
								sendMessage("@cr2@" + (TextUtil.method303(TextUtil.method300(l, 0))),
 name, 7);
							} else if (rights == 1) {
								sendMessage("@cr1@" + (TextUtil.method303(TextUtil.method300(l, 0))),
 name, 7);
							} else {
								sendMessage(TextUtil.method303(TextUtil.method300(l, 0)), name, 3);
							}
						} catch (Exception exception) {
							Signlink.reporterror("cde1");
						}
					}
					opcode = -1;
					return true;
				}
				if (opcode == 183) {
					anInt989 = inputStream.getUByte();
					anInt990 = inputStream.getUByteA();
					while (inputStream.offset < packetSize) {
						int i_171_ = inputStream.getUByte();
						method133(inputStream, 0, i_171_);
					}
					opcode = -1;
					return true;
				}
				if (opcode == 159) {
					int i_172_ = inputStream.getULEShortA2();
					method112((byte) 36, i_172_);
					if (anInt1089 != -1) {
						method44(Client.aBoolean1190, anInt1089);
						anInt1089 = -1;
						drawInventoryRequest = true;
						aBoolean950 = true;
					}
					if (anInt988 != -1) {
						method44(Client.aBoolean1190, anInt988);
						anInt988 = -1;
						aBoolean1240 = true;
					}
					if (anInt1053 != -1) {
						method44(Client.aBoolean1190, anInt1053);
						anInt1053 = -1;
						aBoolean1046 = true;
					}
					if (anInt960 != -1) {
						method44(Client.aBoolean1190, anInt960);
						anInt960 = -1;
					}
					if (anInt1169 != i_172_) {
						method44(Client.aBoolean1190, anInt1169);
						anInt1169 = i_172_;
					}
					if (anInt1244 != 0) {
						anInt1244 = 0;
						aBoolean1240 = true;
					}
					aBoolean1239 = false;
					opcode = -1;
					return true;
				}
				if (opcode == 246) {
					int i_173_ = inputStream.getULEShortA2();
					method112((byte) 36, i_173_);
					if (anInt988 != -1) {
						method44(Client.aBoolean1190, anInt988);
						anInt988 = -1;
						aBoolean1240 = true;
					}
					if (anInt1053 != -1) {
						method44(Client.aBoolean1190, anInt1053);
						anInt1053 = -1;
						aBoolean1046 = true;
					}
					if (anInt960 != -1) {
						method44(Client.aBoolean1190, anInt960);
						anInt960 = -1;
					}
					if (anInt1169 != -1) {
						method44(Client.aBoolean1190, anInt1169);
						anInt1169 = -1;
					}
					if (anInt1089 != i_173_) {
						method44(Client.aBoolean1190, anInt1089);
						anInt1089 = i_173_;
					}
					if (anInt1244 != 0) {
						anInt1244 = 0;
						aBoolean1240 = true;
					}
					drawInventoryRequest = true;
					aBoolean950 = true;
					aBoolean1239 = false;
					opcode = -1;
					return true;
				}
				if (opcode == 49) {
					drawInventoryRequest = true;
					int i_174_ = inputStream.getUByteC();
					int i_175_ = inputStream.getUByte();
					int i_176_ = inputStream.getInt();
					anIntArray843[i_174_] = i_176_;
					anIntArray1029[i_174_] = i_175_;
					anIntArray1054[i_174_] = 1;
					for (int i_177_ = 0; i_177_ < 98; i_177_++) {
						if (i_176_ >= Client.anIntArray952[i_177_]) {
							anIntArray1054[i_174_] = i_177_ + 2;
						}
					}
					opcode = -1;
					return true;
				}
				if (opcode == 206) {
					drawInventoryRequest = true;
					int i_178_ = inputStream.getUShort();
					Interface iComponent = Interface.method195(i_178_);
					int i_179_ = inputStream.getUShort();
					for (int i_180_ = 0; i_180_ < i_179_; i_180_++) {
						iComponent.anIntArray269[i_180_] = inputStream.getULEShortA2();
						int i_181_ = inputStream.getUByteC();
						if (i_181_ == 255) {
							i_181_ = inputStream.getLEInt();
						}
						iComponent.anIntArray224[i_180_] = i_181_;
					}
					for (int i_182_ = i_179_; i_182_ < iComponent.anIntArray269.length; i_182_++) {
						iComponent.anIntArray269[i_182_] = 0;
						iComponent.anIntArray224[i_182_] = 0;
					}
					opcode = -1;
					return true;
				}
				if (opcode == 222 || opcode == 53) {
					int i_183_ = anInt889;
					int i_184_ = anInt890;
					if (opcode == 222) {
						i_184_ = inputStream.getUShort();
						i_183_ = inputStream.getULEShortA2();
						aBoolean1163 = false;
					}
					if (opcode == 53) {
						i_183_ = inputStream.getULEShortA1();
						inputStream.initBitAccess();
						for (int i_185_ = 0; i_185_ < 4; i_185_++) {
							for (int i_186_ = 0; i_186_ < 13; i_186_++) {
								for (int i_187_ = 0; i_187_ < 13; i_187_++) {
									int i_188_ = inputStream.readBits(1);
									if (i_188_ == 1) {
										anIntArrayArrayArray879[i_185_][i_186_][i_187_] = inputStream
											.readBits(26);
									} else {
										anIntArrayArrayArray879[i_185_][i_186_][i_187_] = -1;
									}
								}
							}
						}
						inputStream.finishBitAccess();
						i_184_ = inputStream.getULEShortA1();
						aBoolean1163 = true;
					}
					if (anInt889 == i_183_ && anInt890 == i_184_ && anInt1071 == 2) {
						opcode = -1;
						return true;
					}
					anInt889 = i_183_;
					anInt890 = i_184_;
					anInt1040 = (anInt889 - 6) * 8;
					anInt1041 = (anInt890 - 6) * 8;
					aBoolean1067 = false;
					if ((anInt889 / 8 == 48 || anInt889 / 8 == 49) && anInt890 / 8 == 48) {
						aBoolean1067 = true;
					}
					if (anInt889 / 8 == 48 && anInt890 / 8 == 148) {
						aBoolean1067 = true;
					}
					anInt1071 = 1;
					aLong1229 = System.currentTimeMillis();
					method125(-332, null, "Loading - please wait.");
					if (opcode == 222) {
						int i_189_ = 0;
						for (int i_190_ = (anInt889 - 6) / 8; i_190_ <= (anInt889 + 6) / 8; i_190_++) {
							for (int i_191_ = (anInt890 - 6) / 8; i_191_ <= (anInt890 + 6) / 8; i_191_++) {
								i_189_++;
							}
						}
						aByteArrayArray838 = new byte[i_189_][];
						aByteArrayArray1232 = new byte[i_189_][];
						anIntArray856 = new int[i_189_];
						anIntArray857 = new int[i_189_];
						anIntArray858 = new int[i_189_];
						i_189_ = 0;
						for (int i_192_ = (anInt889 - 6) / 8; i_192_ <= (anInt889 + 6) / 8; i_192_++) {
							for (int i_193_ = (anInt890 - 6) / 8; i_193_ <= (anInt890 + 6) / 8; i_193_++) {
								anIntArray856[i_189_] = (i_192_ << 8) + i_193_;
								if (aBoolean1067
									&& (i_193_ == 49 || i_193_ == 149 || i_193_ == 147
										|| i_192_ == 50 || i_192_ == 49 && i_193_ == 47)) {
									anIntArray857[i_189_] = -1;
									anIntArray858[i_189_] = -1;
									i_189_++;
								} else {
									int i_194_ = (anIntArray857[i_189_] = (aClass32_Sub1_1291
										.method344(0, i_192_, i_193_, 0)));
									if (i_194_ != -1) {
										aClass32_Sub1_1291.method329(3, i_194_);
									}
									int i_195_ = (anIntArray858[i_189_] = (aClass32_Sub1_1291
										.method344(0, i_192_, i_193_, 1)));
									if (i_195_ != -1) {
										aClass32_Sub1_1291.method329(3, i_195_);
									}
									i_189_++;
								}
							}
						}
					}
					if (opcode == 53) {
						int i_196_ = 0;
						int[] is = new int[676];
						for (int i_197_ = 0; i_197_ < 4; i_197_++) {
							for (int i_198_ = 0; i_198_ < 13; i_198_++) {
								for (int i_199_ = 0; i_199_ < 13; i_199_++) {
									int i_200_ = (anIntArrayArrayArray879[i_197_][i_198_][i_199_]);
									if (i_200_ != -1) {
										int i_201_ = i_200_ >> 14 & 0x3ff;
										int i_202_ = i_200_ >> 3 & 0x7ff;
										int i_203_ = (i_201_ / 8 << 8) + i_202_ / 8;
										for (int i_204_ = 0; i_204_ < i_196_; i_204_++) {
											if (is[i_204_] == i_203_) {
												i_203_ = -1;
												break;
											}
										}
										if (i_203_ != -1) {
											is[i_196_++] = i_203_;
										}
									}
								}
							}
						}
						aByteArrayArray838 = new byte[i_196_][];
						aByteArrayArray1232 = new byte[i_196_][];
						anIntArray856 = new int[i_196_];
						anIntArray857 = new int[i_196_];
						anIntArray858 = new int[i_196_];
						for (int i_205_ = 0; i_205_ < i_196_; i_205_++) {
							int i_206_ = anIntArray856[i_205_] = is[i_205_];
							int i_207_ = i_206_ >> 8 & 0xff;
							int i_208_ = i_206_ & 0xff;
							int i_209_ = (anIntArray857[i_205_] = aClass32_Sub1_1291.method344(0,
								i_207_, i_208_, 0));
							if (i_209_ != -1) {
								aClass32_Sub1_1291.method329(3, i_209_);
							}
							int i_210_ = (anIntArray858[i_205_] = aClass32_Sub1_1291.method344(0,
								i_207_, i_208_, 1));
							if (i_210_ != -1) {
								aClass32_Sub1_1291.method329(3, i_210_);
							}
						}
					}
					int i_211_ = anInt1040 - anInt1042;
					int i_212_ = anInt1041 - anInt1043;
					anInt1042 = anInt1040;
					anInt1043 = anInt1041;
					for (int i_213_ = 0; i_213_ < 16384; i_213_++) {
						Npc npc = totalNpcs[i_213_];
						if (npc != null) {
							for (int i_214_ = 0; i_214_ < 10; i_214_++) {
								((ObjectInstance) npc).anIntArray1586[i_214_] -= i_211_;
								((ObjectInstance) npc).anIntArray1587[i_214_] -= i_212_;
							}
							((ObjectInstance) npc).anInt1610 -= i_211_ * 128;
							((ObjectInstance) npc).anInt1611 -= i_212_ * 128;
						}
					}
					for (int i_215_ = 0; i_215_ < anInt968; i_215_++) {
						Player player = totalPlayers[i_215_];
						if (player != null) {
							for (int i_216_ = 0; i_216_ < 10; i_216_++) {
								((ObjectInstance) player).anIntArray1586[i_216_] -= i_211_;
								((ObjectInstance) player).anIntArray1587[i_216_] -= i_212_;
							}
							((ObjectInstance) player).anInt1610 -= i_211_ * 128;
							((ObjectInstance) player).anInt1611 -= i_212_ * 128;
						}
					}
					aBoolean1209 = true;
					int i_217_ = 0;
					int i_218_ = 104;
					int i_219_ = 1;
					if (i_211_ < 0) {
						i_217_ = 103;
						i_218_ = -1;
						i_219_ = -1;
					}
					int i_220_ = 0;
					int i_221_ = 104;
					int i_222_ = 1;
					if (i_212_ < 0) {
						i_220_ = 103;
						i_221_ = -1;
						i_222_ = -1;
					}
					for (int i_223_ = i_217_; i_223_ != i_218_; i_223_ += i_219_) {
						for (int i_224_ = i_220_; i_224_ != i_221_; i_224_ += i_222_) {
							int i_225_ = i_223_ + i_211_;
							int i_226_ = i_224_ + i_212_;
							for (int i_227_ = 0; i_227_ < 4; i_227_++) {
								if (i_225_ >= 0 && i_226_ >= 0 && i_225_ < 104 && i_226_ < 104) {
									aDequeArrayArrayArray1323[i_227_][i_223_][i_224_] = (aDequeArrayArrayArray1323[i_227_][i_225_][i_226_]);
								} else {
									aDequeArrayArrayArray1323[i_227_][i_223_][i_224_] = null;
								}
							}
						}
					}
					for (Class50_Sub2 class50_sub2 = (Class50_Sub2) aDeque_1261.method158(); class50_sub2 != null; class50_sub2 = (Class50_Sub2) aDeque_1261
						.method160(1)) {
						class50_sub2.anInt1393 -= i_211_;
						class50_sub2.anInt1394 -= i_212_;
						if (class50_sub2.anInt1393 < 0 || class50_sub2.anInt1394 < 0
							|| class50_sub2.anInt1393 >= 104 || class50_sub2.anInt1394 >= 104) {
							class50_sub2.method453();
						}
					}
					if (anInt1120 != 0) {
						anInt1120 -= i_211_;
						anInt1121 -= i_212_;
					}
					aBoolean1211 = false;
					opcode = -1;
					return true;
				}
				if (opcode == 190) {
					anInt1057 = inputStream.getULEShort() * 30;
					opcode = -1;
					return true;
				}
				if (opcode == 41 || opcode == 121 || opcode == 203 || opcode == 106
					|| opcode == 59 || opcode == 181 || opcode == 208 || opcode == 107
					|| opcode == 142 || opcode == 88 || opcode == 152) {
					method133(inputStream, 0, opcode);
					opcode = -1;
					return true;
				}
				if (opcode == 125) {
					if (anInt1285 == 12) {
						drawInventoryRequest = true;
					}
					anInt1324 = inputStream.getUByte();
					opcode = -1;
					return true;
				}
				if (opcode == 21) {
					int i_228_ = inputStream.getUShort();
					int i_229_ = inputStream.getULEShort();
					int i_230_ = inputStream.getULEShortA2();
					if (i_229_ == 65535) {
						Interface.method195(i_230_).anInt283 = 0;
						opcode = -1;
						return true;
					}
					ItemDefinition itemDefinition = ItemDefinition.method212(i_229_);
					Interface.method195(i_230_).anInt283 = 4;
					Interface.method195(i_230_).anInt284 = i_229_;
					Interface.method195(i_230_).anInt252 = itemDefinition.anInt359;
					Interface.method195(i_230_).anInt253 = itemDefinition.anInt356;
					Interface.method195(i_230_).anInt251 = itemDefinition.zoom * 100 / i_228_;
					opcode = -1;
					return true;
				}
				if (opcode == 3) {
					aBoolean1211 = true;
					anInt874 = inputStream.getUByte();
					anInt875 = inputStream.getUByte();
					anInt876 = inputStream.getUShort();
					anInt877 = inputStream.getUByte();
					anInt878 = inputStream.getUByte();
					if (anInt878 >= 100) {
						anInt1216 = anInt874 * 128 + 64;
						anInt1218 = anInt875 * 128 + 64;
						anInt1217 = method110(anInt1218, anInt1216, (byte) 9, anInt1091) - anInt876;
					}
					opcode = -1;
					return true;
				}
				if (opcode == 2) {
					int i_231_ = inputStream.getULEShortA2();
					int i_232_ = inputStream.getUShortA();
					Interface iComponent = Interface.method195(i_231_);
					if (iComponent.anInt286 != i_232_ || i_232_ == -1) {
						iComponent.anInt286 = i_232_;
						iComponent.anInt235 = 0;
						iComponent.anInt227 = 0;
					}
					opcode = -1;
					return true;
				}
				if (opcode == 71) {
					method48(inputStream, aBoolean1038, packetSize);
					opcode = -1;
					return true;
				}
				if (opcode == 226) {
					anInt855 = packetSize / 8;
					for (int i_233_ = 0; i_233_ < anInt855; i_233_++) {
						aLongArray1073[i_233_] = inputStream.getLong();
					}
					opcode = -1;
					return true;
				}
				if (opcode == 10) {
					int i_234_ = inputStream.getUByteS();
					int i_235_ = inputStream.getULEShortA1();
					if (i_235_ == 65535) {
						i_235_ = -1;
					}
					if (anIntArray1081[i_234_] != i_235_) {
						method44(Client.aBoolean1190, anIntArray1081[i_234_]);
						anIntArray1081[i_234_] = i_235_;
					}
					drawInventoryRequest = true;
					aBoolean950 = true;
					opcode = -1;
					return true;
				}
				if (opcode == 219) {
					int i_236_ = inputStream.getULEShort();
					Interface iComponent = Interface.method195(i_236_);
					for (int i_237_ = 0; i_237_ < iComponent.anIntArray269.length; i_237_++) {
						iComponent.anIntArray269[i_237_] = -1;
						iComponent.anIntArray269[i_237_] = 0;
					}
					opcode = -1;
					return true;
				}
				if (opcode == 238) {
					anInt1213 = inputStream.getUByte();
					if (anInt1213 == anInt1285) {
						if (anInt1213 == 3) {
							anInt1285 = 1;
						} else {
							anInt1285 = 3;
						}
						drawInventoryRequest = true;
					}
					opcode = -1;
					return true;
				}
				if (opcode == 148) {
					aBoolean1211 = false;
					for (int i_238_ = 0; i_238_ < 5; i_238_++) {
						aBooleanArray927[i_238_] = false;
					}
					opcode = -1;
					return true;
				}
				if (opcode == 126) {
					anInt1068 = inputStream.getUByte();
					anInt961 = inputStream.getULEShort();
					opcode = -1;
					return true;
				}
				if (opcode == 75) {
					anInt989 = inputStream.getUByteC();
					anInt990 = inputStream.getUByteA();
					opcode = -1;
					return true;
				}
				if (opcode == 253) {
					int i_239_ = inputStream.getULEShort();
					int i_240_ = inputStream.getULEShortA1();
					method112((byte) 36, i_240_);
					if (i_239_ != -1) {
						method112((byte) 36, i_239_);
					}
					if (anInt1169 != -1) {
						method44(Client.aBoolean1190, anInt1169);
						anInt1169 = -1;
					}
					if (anInt1089 != -1) {
						method44(Client.aBoolean1190, anInt1089);
						anInt1089 = -1;
					}
					if (anInt988 != -1) {
						method44(Client.aBoolean1190, anInt988);
						anInt988 = -1;
					}
					if (anInt1053 != i_240_) {
						method44(Client.aBoolean1190, anInt1053);
						anInt1053 = i_240_;
					}
					if (anInt960 != i_240_) {
						method44(Client.aBoolean1190, anInt960);
						anInt960 = i_239_;
					}
					anInt1244 = 0;
					aBoolean1239 = false;
					opcode = -1;
					return true;
				}
				if (opcode == 251) {
					anInt860 = inputStream.getUByte();
					drawInventoryRequest = true;
					opcode = -1;
					return true;
				}
				if (opcode == 18) {
					int i_241_ = inputStream.getUShort();
					int i_242_ = inputStream.getULEShortA1();
					int i_243_ = inputStream.getULEShort();
					Interface.method195(i_242_).anInt218 = (i_241_ << 16) + i_243_;
					opcode = -1;
					return true;
				}
				if (opcode == 90) {
					method96(packetSize, 69, inputStream);
					aBoolean1209 = false;
					opcode = -1;
					return true;
				}
				if (opcode == 113) {
					for (int i_244_ = 0; i_244_ < anIntArray1039.length; i_244_++) {
						if (anIntArray1039[i_244_] != anIntArray1005[i_244_]) {
							anIntArray1039[i_244_] = anIntArray1005[i_244_];
							method105(0, i_244_);
							drawInventoryRequest = true;
						}
					}
					opcode = -1;
					return true;
				}
				if (opcode == 232) {
					int i_245_ = inputStream.getULEShortA2();
					String string = inputStream.getString();
					Interface.method195(i_245_).aString230 = string;
					if (Interface.method195(i_245_).anInt248 == anIntArray1081[anInt1285]) {
						drawInventoryRequest = true;
					}
					opcode = -1;
					return true;
				}
				if (opcode == 200) {
					int i_246_ = inputStream.getUShort();
					int i_247_ = inputStream.getULEShortA2();
					Interface iComponent = Interface.method195(i_246_);
					if (iComponent != null && iComponent.anInt236 == 0) {
						if (i_247_ < 0) {
							i_247_ = 0;
						}
						if (i_247_ > iComponent.anInt285 - iComponent.anInt238) {
							i_247_ = iComponent.anInt285 - iComponent.anInt238;
						}
						iComponent.anInt231 = i_247_;
					}
					opcode = -1;
					return true;
				}
				Signlink.reporterror("T1 - " + opcode + "," + packetSize + " - " + anInt904 + ","
					+ anInt905);
				method124(true);
			} catch (IOException ioexception) {
				method59(1);
			} catch (Exception exception) {
				String string = ("T2 - "
					+ opcode
					+ ","
					+ anInt904
					+ ","
					+ anInt905
					+ " - "
					+ packetSize
					+ ","
					+ (anInt1040 + (((ObjectInstance) Client.myPlayer).anIntArray1586[0]))
					+ ","
					+ (anInt1041 + (((ObjectInstance) Client.myPlayer).anIntArray1587[0])) + " - ");
				for (int i_248_ = 0; i_248_ < packetSize && i_248_ < 50; i_248_++) {
					string += (inputStream.payload[i_248_] + ",");
				}
				Signlink.reporterror(string);
				method124(true);
			}
			return true;
		} catch (RuntimeException runtimeexception) {
			Signlink.reporterror("11063, " + runtimeexception.toString());
			throw new RuntimeException();
		}
	}

	public final void method34(byte i) {
		if ((anInt1183 >= 2 || anInt1146 != 0 || anInt1171 != 0) && i == -79) {
			String string;
			if (anInt1146 == 1 && anInt1183 < 2) {
				string = "Use " + ((Client) this).aString1150 + " with...";
			} else if (anInt1171 == 1 && anInt1183 < 2) {
				string = ((Client) this).aString1174 + "...";
			} else {
				string = aStringArray1184[anInt1183 - 1];
			}
			if (anInt1183 > 2) {
				string += "@whi@ / " + (anInt1183 - 2) + " more options";
			}
			aFont_1061.method490(true, Client.anInt1325 / 1000, 4, 16777215, 15, string);
		}
	}

	public final boolean method35(boolean bool, boolean bool_249_, int i, int i_250_, int i_251_,
		int i_252_, int i_253_, int i_254_, int i_255_, int i_256_, int i_257_, int i_258_) {
		int i_259_ = 104;
		int i_260_ = 104;
		for (int i_261_ = 0; i_261_ < i_259_; i_261_++) {
			for (int i_262_ = 0; i_262_ < i_260_; i_262_++) {
				anIntArrayArray885[i_261_][i_262_] = 0;
				anIntArrayArray1189[i_261_][i_262_] = 99999999;
			}
		}
		int i_263_ = i_258_;
		int i_264_ = i_250_;
		anIntArrayArray885[i_258_][i_250_] = 99;
		anIntArrayArray1189[i_258_][i_250_] = 0;
		int i_265_ = 0;
		int i_266_ = 0;
		anIntArray1123[i_265_] = i_258_;
		anIntArray1124[i_265_++] = i_250_;
		boolean bool_267_ = false;
		int i_268_ = anIntArray1123.length;
		int[][] is = aCollisionMapArray1260[anInt1091].anIntArrayArray757;
		while (i_266_ != i_265_) {
			i_263_ = anIntArray1123[i_266_];
			i_264_ = anIntArray1124[i_266_];
			i_266_ = (i_266_ + 1) % i_268_;
			if (i_263_ == i_255_ && i_264_ == i) {
				bool_267_ = true;
				break;
			}
			if (i_254_ != 0) {
				if ((i_254_ < 5 || i_254_ == 10)
					&& aCollisionMapArray1260[anInt1091].method431(i_255_, 0, i, i_254_ - 1,
						i_263_, i_264_, i_257_)) {
					bool_267_ = true;
					break;
				}
				if (i_254_ < 10
					&& aCollisionMapArray1260[anInt1091].method432(-37, i_264_, i_255_, i_263_,
						i_257_, i_254_ - 1, i)) {
					bool_267_ = true;
					break;
				}
			}
			if (i_251_ != 0
				&& i_252_ != 0
				&& aCollisionMapArray1260[anInt1091].method433(i_251_, i_263_, i_255_, i_256_,
					i_252_, i, i_264_)) {
				bool_267_ = true;
				break;
			}
			int i_269_ = anIntArrayArray1189[i_263_][i_264_] + 1;
			if (i_263_ > 0 && anIntArrayArray885[i_263_ - 1][i_264_] == 0
				&& (is[i_263_ - 1][i_264_] & 0x1280108) == 0) {
				anIntArray1123[i_265_] = i_263_ - 1;
				anIntArray1124[i_265_] = i_264_;
				i_265_ = (i_265_ + 1) % i_268_;
				anIntArrayArray885[i_263_ - 1][i_264_] = 2;
				anIntArrayArray1189[i_263_ - 1][i_264_] = i_269_;
			}
			if (i_263_ < i_259_ - 1 && anIntArrayArray885[i_263_ + 1][i_264_] == 0
				&& (is[i_263_ + 1][i_264_] & 0x1280180) == 0) {
				anIntArray1123[i_265_] = i_263_ + 1;
				anIntArray1124[i_265_] = i_264_;
				i_265_ = (i_265_ + 1) % i_268_;
				anIntArrayArray885[i_263_ + 1][i_264_] = 8;
				anIntArrayArray1189[i_263_ + 1][i_264_] = i_269_;
			}
			if (i_264_ > 0 && anIntArrayArray885[i_263_][i_264_ - 1] == 0
				&& (is[i_263_][i_264_ - 1] & 0x1280102) == 0) {
				anIntArray1123[i_265_] = i_263_;
				anIntArray1124[i_265_] = i_264_ - 1;
				i_265_ = (i_265_ + 1) % i_268_;
				anIntArrayArray885[i_263_][i_264_ - 1] = 1;
				anIntArrayArray1189[i_263_][i_264_ - 1] = i_269_;
			}
			if (i_264_ < i_260_ - 1 && anIntArrayArray885[i_263_][i_264_ + 1] == 0
				&& (is[i_263_][i_264_ + 1] & 0x1280120) == 0) {
				anIntArray1123[i_265_] = i_263_;
				anIntArray1124[i_265_] = i_264_ + 1;
				i_265_ = (i_265_ + 1) % i_268_;
				anIntArrayArray885[i_263_][i_264_ + 1] = 4;
				anIntArrayArray1189[i_263_][i_264_ + 1] = i_269_;
			}
			if (i_263_ > 0 && i_264_ > 0 && anIntArrayArray885[i_263_ - 1][i_264_ - 1] == 0
				&& (is[i_263_ - 1][i_264_ - 1] & 0x128010e) == 0
				&& (is[i_263_ - 1][i_264_] & 0x1280108) == 0
				&& (is[i_263_][i_264_ - 1] & 0x1280102) == 0) {
				anIntArray1123[i_265_] = i_263_ - 1;
				anIntArray1124[i_265_] = i_264_ - 1;
				i_265_ = (i_265_ + 1) % i_268_;
				anIntArrayArray885[i_263_ - 1][i_264_ - 1] = 3;
				anIntArrayArray1189[i_263_ - 1][i_264_ - 1] = i_269_;
			}
			if (i_263_ < i_259_ - 1 && i_264_ > 0
				&& anIntArrayArray885[i_263_ + 1][i_264_ - 1] == 0
				&& (is[i_263_ + 1][i_264_ - 1] & 0x1280183) == 0
				&& (is[i_263_ + 1][i_264_] & 0x1280180) == 0
				&& (is[i_263_][i_264_ - 1] & 0x1280102) == 0) {
				anIntArray1123[i_265_] = i_263_ + 1;
				anIntArray1124[i_265_] = i_264_ - 1;
				i_265_ = (i_265_ + 1) % i_268_;
				anIntArrayArray885[i_263_ + 1][i_264_ - 1] = 9;
				anIntArrayArray1189[i_263_ + 1][i_264_ - 1] = i_269_;
			}
			if (i_263_ > 0 && i_264_ < i_260_ - 1
				&& anIntArrayArray885[i_263_ - 1][i_264_ + 1] == 0
				&& (is[i_263_ - 1][i_264_ + 1] & 0x1280138) == 0
				&& (is[i_263_ - 1][i_264_] & 0x1280108) == 0
				&& (is[i_263_][i_264_ + 1] & 0x1280120) == 0) {
				anIntArray1123[i_265_] = i_263_ - 1;
				anIntArray1124[i_265_] = i_264_ + 1;
				i_265_ = (i_265_ + 1) % i_268_;
				anIntArrayArray885[i_263_ - 1][i_264_ + 1] = 6;
				anIntArrayArray1189[i_263_ - 1][i_264_ + 1] = i_269_;
			}
			if (i_263_ < i_259_ - 1 && i_264_ < i_260_ - 1
				&& anIntArrayArray885[i_263_ + 1][i_264_ + 1] == 0
				&& (is[i_263_ + 1][i_264_ + 1] & 0x12801e0) == 0
				&& (is[i_263_ + 1][i_264_] & 0x1280180) == 0
				&& (is[i_263_][i_264_ + 1] & 0x1280120) == 0) {
				anIntArray1123[i_265_] = i_263_ + 1;
				anIntArray1124[i_265_] = i_264_ + 1;
				i_265_ = (i_265_ + 1) % i_268_;
				anIntArrayArray885[i_263_ + 1][i_264_ + 1] = 12;
				anIntArrayArray1189[i_263_ + 1][i_264_ + 1] = i_269_;
			}
		}
		anInt1126 = 0;
		if (!bool_267_) {
			if (bool) {
				int i_270_ = 1000;
				int i_271_ = 100;
				int i_272_ = 10;
				for (int i_273_ = i_255_ - i_272_; i_273_ <= i_255_ + i_272_; i_273_++) {
					for (int i_274_ = i - i_272_; i_274_ <= i + i_272_; i_274_++) {
						if (i_273_ >= 0 && i_274_ >= 0 && i_273_ < 104 && i_274_ < 104
							&& anIntArrayArray1189[i_273_][i_274_] < 100) {
							int i_275_ = 0;
							if (i_273_ < i_255_) {
								i_275_ = i_255_ - i_273_;
							} else if (i_273_ > i_255_ + i_251_ - 1) {
								i_275_ = i_273_ - (i_255_ + i_251_ - 1);
							}
							int i_276_ = 0;
							if (i_274_ < i) {
								i_276_ = i - i_274_;
							} else if (i_274_ > i + i_252_ - 1) {
								i_276_ = i_274_ - (i + i_252_ - 1);
							}
							int i_277_ = i_275_ * i_275_ + i_276_ * i_276_;
							if (i_277_ < i_270_
								|| (i_277_ == i_270_ && (anIntArrayArray1189[i_273_][i_274_] < i_271_))) {
								i_270_ = i_277_;
								i_271_ = anIntArrayArray1189[i_273_][i_274_];
								i_263_ = i_273_;
								i_264_ = i_274_;
							}
						}
					}
				}
				if (i_270_ == 1000) {
					return false;
				}
				if (i_263_ == i_258_ && i_264_ == i_250_) {
					return false;
				}
				anInt1126 = 1;
			} else {
				return false;
			}
		}
		i_266_ = 0;
		if (bool_249_) {
			method6();
		}
		anIntArray1123[i_266_] = i_263_;
		anIntArray1124[i_266_++] = i_264_;
		int i_279_;
		int i_278_ = i_279_ = anIntArrayArray885[i_263_][i_264_];
		while (i_263_ != i_258_ || i_264_ != i_250_) {
			if (i_278_ != i_279_) {
				i_279_ = i_278_;
				anIntArray1123[i_266_] = i_263_;
				anIntArray1124[i_266_++] = i_264_;
			}
			if ((i_278_ & 0x2) != 0) {
				i_263_++;
			} else if ((i_278_ & 0x8) != 0) {
				i_263_--;
			}
			if ((i_278_ & 0x1) != 0) {
				i_264_++;
			} else if ((i_278_ & 0x4) != 0) {
				i_264_--;
			}
			i_278_ = anIntArrayArray885[i_263_][i_264_];
		}
		if (i_266_ > 0) {
			i_268_ = i_266_;
			if (i_268_ > 25) {
				i_268_ = 25;
			}
			i_266_--;
			int i_280_ = anIntArray1123[i_266_];
			int i_281_ = anIntArray1124[i_266_];
			if (i_253_ == 0) {
				aPacket_964.putOpcode(28);
				aPacket_964.putByte(i_268_ + i_268_ + 3);
			}
			if (i_253_ == 1) {
				aPacket_964.putOpcode(213);
				aPacket_964.putByte(i_268_ + i_268_ + 3 + 14);
			}
			if (i_253_ == 2) {
				aPacket_964.putOpcode(247);
				aPacket_964.putByte(i_268_ + i_268_ + 3);
			}
			aPacket_964.putLEShortA(i_280_ + anInt1040);
			aPacket_964.putByte(anIntArray32[5] == 1 ? 1 : 0);
			aPacket_964.putLEShortA(i_281_ + anInt1041);
			anInt1120 = anIntArray1123[0];
			anInt1121 = anIntArray1124[0];
			for (int i_282_ = 1; i_282_ < i_268_; i_282_++) {
				i_266_--;
				aPacket_964.putByte(anIntArray1123[i_266_] - i_280_);
				aPacket_964.putByteS(anIntArray1124[i_266_] - i_281_);
			}
			return true;
		}
		if (i_253_ == 1) {
			return false;
		}
		return true;
	}

	private final void method36(int i) {
		if (i != 16220) {
			anInt1328 = 458;
		}
		if (anInt1071 == 2) {
			for (Class50_Sub2 class50_sub2 = (Class50_Sub2) aDeque_1261.method158(); class50_sub2 != null; class50_sub2 = (Class50_Sub2) aDeque_1261
				.method160(1)) {
				if (class50_sub2.anInt1390 > 0) {
					class50_sub2.anInt1390--;
				}
				if (class50_sub2.anInt1390 == 0) {
					if (class50_sub2.anInt1387 < 0
						|| Class8.method170(class50_sub2.anInt1389, aByte1143,
							class50_sub2.anInt1387)) {
						method45(class50_sub2.anInt1388, class50_sub2.anInt1393,
							class50_sub2.anInt1387, class50_sub2.anInt1394, class50_sub2.anInt1391,
							class50_sub2.anInt1389, (byte) 1, class50_sub2.anInt1392);
						class50_sub2.method453();
					}
				} else {
					if (class50_sub2.anInt1395 > 0) {
						class50_sub2.anInt1395--;
					}
					if (class50_sub2.anInt1395 == 0
						&& class50_sub2.anInt1393 >= 1
						&& class50_sub2.anInt1394 >= 1
						&& class50_sub2.anInt1393 <= 102
						&& class50_sub2.anInt1394 <= 102
						&& (class50_sub2.anInt1384 < 0 || Class8.method170(class50_sub2.anInt1386,
							aByte1143, class50_sub2.anInt1384))) {
						method45(class50_sub2.anInt1385, class50_sub2.anInt1393,
							class50_sub2.anInt1384, class50_sub2.anInt1394, class50_sub2.anInt1391,
							class50_sub2.anInt1386, (byte) 1, class50_sub2.anInt1392);
						class50_sub2.anInt1395 = -1;
						if (class50_sub2.anInt1384 == class50_sub2.anInt1387
							&& class50_sub2.anInt1387 == -1) {
							class50_sub2.method453();
						} else if ((class50_sub2.anInt1384 == class50_sub2.anInt1387)
							&& (class50_sub2.anInt1385 == class50_sub2.anInt1388)
							&& (class50_sub2.anInt1386 == class50_sub2.anInt1389)) {
							class50_sub2.method453();
						}
					}
				}
			}
		}
	}

	public final String method37(int i) {
		if (i != -42588) {
			opcode = inputStream.getUByte();
		}
		if (Signlink.mainapp != null) {
			return Signlink.mainapp.getDocumentBase().getHost().toLowerCase();
		}
		if (frame != null) {
			return "runescape.com";
		}
		return super.getDocumentBase().getHost().toLowerCase();
	}

	public final void method38(int i, int i_283_, int i_284_, Player player, int i_285_) {
		if (player != Client.myPlayer && anInt1183 < 400) {
			if (i_285_ != 0) {
				Client.aBoolean963 = !Client.aBoolean963;
			}
			String string;
			if ((((Player) player).anInt1759) == 0) {
				string = (((Player) player).aString1751
					+ Client.method92(((Player) player).anInt1753,
						(((Player) Client.myPlayer).anInt1753), 736) + " (level-"
					+ ((Player) player).anInt1753 + ")");
			} else {
				string = (((Player) player).aString1751 + " (skill-" + ((Player) player).anInt1759 + ")");
			}
			if (anInt1146 == 1) {
				aStringArray1184[anInt1183] = ("Use " + ((Client) this).aString1150 + " with @whi@" + string);
				anIntArray981[anInt1183] = 596;
				anIntArray982[anInt1183] = i;
				anIntArray979[anInt1183] = i_284_;
				anIntArray980[anInt1183] = i_283_;
				anInt1183++;
			} else if (anInt1171 == 1) {
				if ((anInt1173 & 0x8) == 8) {
					aStringArray1184[anInt1183] = ((Client) this).aString1174 + " @whi@" + string;
					anIntArray981[anInt1183] = 918;
					anIntArray982[anInt1183] = i;
					anIntArray979[anInt1183] = i_284_;
					anIntArray980[anInt1183] = i_283_;
					anInt1183++;
				}
			} else {
				for (int i_286_ = 4; i_286_ >= 0; i_286_--) {
					if (aStringArray1069[i_286_] != null) {
						aStringArray1184[anInt1183] = aStringArray1069[i_286_] + " @whi@" + string;
						int i_287_ = 0;
						if (aStringArray1069[i_286_].equalsIgnoreCase("attack")) {
							if (((Player) player).anInt1753 > (((Player) Client.myPlayer).anInt1753)) {
								i_287_ = 2000;
							}
							if ((((Player) Client.myPlayer).anInt1766 != 0)
								&& (((Player) player).anInt1766 != 0)) {
								if ((((Player) Client.myPlayer).anInt1766) == ((Player) player).anInt1766) {
									i_287_ = 2000;
								} else {
									i_287_ = 0;
								}
							}
						} else if (aBooleanArray1070[i_286_]) {
							i_287_ = 2000;
						}
						if (i_286_ == 0) {
							anIntArray981[anInt1183] = i_287_ + 200;
						}
						if (i_286_ == 1) {
							anIntArray981[anInt1183] = i_287_ + 493;
						}
						if (i_286_ == 2) {
							anIntArray981[anInt1183] = i_287_ + 408;
						}
						if (i_286_ == 3) {
							anIntArray981[anInt1183] = i_287_ + 677;
						}
						if (i_286_ == 4) {
							anIntArray981[anInt1183] = i_287_ + 876;
						}
						anIntArray982[anInt1183] = i;
						anIntArray979[anInt1183] = i_284_;
						anIntArray980[anInt1183] = i_283_;
						anInt1183++;
					}
				}
			}
			for (int i_288_ = 0; i_288_ < anInt1183; i_288_++) {
				if (anIntArray981[i_288_] == 14) {
					aStringArray1184[i_288_] = "Walk here @whi@" + string;
					break;
				}
			}
		}
	}

	public final void method39(boolean bool) {
		if (!bool) {
			aDequeArrayArrayArray1323 = null;
		}
		if (anInt28 == 1) {
			if (anInt29 >= 6 && anInt29 <= 106 && anInt30 >= 467 && anInt30 <= 499) {
				anInt1006 = (anInt1006 + 1) % 4;
				aBoolean1212 = true;
				aBoolean1240 = true;
				aPacket_964.putOpcode(176);
				aPacket_964.putByte(anInt1006);
				aPacket_964.putByte(anInt887);
				aPacket_964.putByte(anInt1227);
			}
			if (anInt29 >= 135 && anInt29 <= 235 && anInt30 >= 467 && anInt30 <= 499) {
				anInt887 = (anInt887 + 1) % 3;
				aBoolean1212 = true;
				aBoolean1240 = true;
				aPacket_964.putOpcode(176);
				aPacket_964.putByte(anInt1006);
				aPacket_964.putByte(anInt887);
				aPacket_964.putByte(anInt1227);
			}
			if (anInt29 >= 273 && anInt29 <= 373 && anInt30 >= 467 && anInt30 <= 499) {
				anInt1227 = (anInt1227 + 1) % 3;
				aBoolean1212 = true;
				aBoolean1240 = true;
				aPacket_964.putOpcode(176);
				aPacket_964.putByte(anInt1006);
				aPacket_964.putByte(anInt887);
				aPacket_964.putByte(anInt1227);
			}
			if (anInt29 >= 412 && anInt29 <= 512 && anInt30 >= 467 && anInt30 <= 499) {
				if (anInt1169 == -1) {
					method15(false);
					aString839 = "";
					aBoolean1098 = false;
					anInt1231 = anInt1169 = Interface.anInt246;
				} else {
					sendMessage("", "Please close the interface you have open before using 'report abuse'", 0);
				}
			}
			Client.anInt1160++;
			if (Client.anInt1160 > 161) {
				Client.anInt1160 = 0;
				aPacket_964.putOpcode(22);
				aPacket_964.putShort(38304);
			}
		}
	}

	private final void method40(int i, Packet packet, int i_289_) {
		for (int i_290_ = 0; i_290_ < anInt973; i_290_++) {
			int i_291_ = anIntArray974[i_290_];
			Player player = totalPlayers[i_291_];
			int i_292_ = packet.getUByte();
			if ((i_292_ & 0x20) != 0) {
				i_292_ += packet.getUByte() << 8;
			}
			method63(2, i_291_, player, i_292_, packet);
		}
		i = 70 / i;
	}

	private final void method41(int i, boolean bool, Packet packet) {
		packet.initBitAccess();
		int i_293_ = packet.readBits(1);
		if (i_293_ != 0) {
			int i_294_ = packet.readBits(2);
			aBoolean1137 &= bool;
			if (i_294_ == 0) {
				anIntArray974[anInt973++] = anInt969;
			} else if (i_294_ == 1) {
				int i_295_ = packet.readBits(3);
				Client.myPlayer.method577(false, i_295_, -808);
				int i_296_ = packet.readBits(1);
				if (i_296_ == 1) {
					anIntArray974[anInt973++] = anInt969;
				}
			} else if (i_294_ == 2) {
				int i_297_ = packet.readBits(3);
				Client.myPlayer.method577(true, i_297_, -808);
				int i_298_ = packet.readBits(3);
				Client.myPlayer.method577(true, i_298_, -808);
				int i_299_ = packet.readBits(1);
				if (i_299_ == 1) {
					anIntArray974[anInt973++] = anInt969;
				}
			} else if (i_294_ == 3) {
				int i_300_ = packet.readBits(1);
				anInt1091 = packet.readBits(2);
				int i_301_ = packet.readBits(7);
				int i_302_ = packet.readBits(7);
				int i_303_ = packet.readBits(1);
				if (i_303_ == 1) {
					anIntArray974[anInt973++] = anInt969;
				}
				Client.myPlayer.method579(i_301_, (byte) 5, i_300_ == 1, i_302_);
			}
		}
	}

	public final void method42(int i, int i_304_, Interface iComponent, byte i_305_, int i_306_,
		int i_307_, int i_308_, int i_309_, int i_310_) {
		if (aBoolean1127) {
			anInt1303 = 32;
		} else {
			anInt1303 = 0;
		}
		aBoolean1127 = false;
		if (i_305_ != 102) {
			for (int i_311_ = 1; i_311_ > 0; i_311_++) {
				/* empty */
			}
		}
		if (i_308_ >= i_310_ && i_308_ < i_310_ + 16 && i_306_ >= i_304_ && i_306_ < i_304_ + 16) {
			iComponent.anInt231 -= anInt1094 * 4;
			if (i_307_ == 1) {
				drawInventoryRequest = true;
			}
			if (i_307_ == 2 || i_307_ == 3) {
				aBoolean1240 = true;
			}
		} else if (i_308_ >= i_310_ && i_308_ < i_310_ + 16 && i_306_ >= i_304_ + i_309_ - 16
			&& i_306_ < i_304_ + i_309_) {
			iComponent.anInt231 += anInt1094 * 4;
			if (i_307_ == 1) {
				drawInventoryRequest = true;
			}
			if (i_307_ == 2 || i_307_ == 3) {
				aBoolean1240 = true;
			}
		} else if (i_308_ >= i_310_ - anInt1303 && i_308_ < i_310_ + 16 + anInt1303
			&& i_306_ >= i_304_ + 16 && i_306_ < i_304_ + i_309_ - 16 && anInt1094 > 0) {
			int i_312_ = (i_309_ - 32) * i_309_ / i;
			if (i_312_ < 8) {
				i_312_ = 8;
			}
			int i_313_ = i_306_ - i_304_ - 16 - i_312_ / 2;
			int i_314_ = i_309_ - 32 - i_312_;
			iComponent.anInt231 = (i - i_309_) * i_313_ / i_314_;
			if (i_307_ == 1) {
				drawInventoryRequest = true;
			}
			if (i_307_ == 2 || i_307_ == 3) {
				aBoolean1240 = true;
			}
			aBoolean1127 = true;
		}
	}

	public final void method43(byte i) {
		if (anInt1146 == 0 && anInt1171 == 0) {
			aStringArray1184[anInt1183] = "Walk here";
			anIntArray981[anInt1183] = 14;
			anIntArray979[anInt1183] = anInt22;
			anIntArray980[anInt1183] = anInt23;
			anInt1183++;
		}
		int i_315_ = -1;
		if (i != 7) {
			opcode = -1;
		}
		for (int i_316_ = 0; i_316_ < Model.anInt1708; i_316_++) {
			int i_317_ = Model.anIntArray1709[i_316_];
			int i_318_ = i_317_ & 0x7f;
			int i_319_ = i_317_ >> 7 & 0x7f;
			int i_320_ = i_317_ >> 29 & 0x3;
			int i_321_ = i_317_ >> 14 & 0x7fff;
			if (i_317_ != i_315_) {
				i_315_ = i_317_;
				if (i_320_ == 2 && aClass22_1164.method271(anInt1091, i_318_, i_319_, i_317_) >= 0) {
					ObjectDefinition objectDefinition = ObjectDefinition.method434(i_321_);
					if (objectDefinition.anIntArray805 != null) {
						objectDefinition = objectDefinition.method435();
					}
					if (objectDefinition == null) {
						continue;
					}
					if (anInt1146 == 1) {
						aStringArray1184[anInt1183] = ("Use " + ((Client) this).aString1150
							+ " with @cya@" + objectDefinition.aString776);
						anIntArray981[anInt1183] = 467;
						anIntArray982[anInt1183] = i_317_;
						anIntArray979[anInt1183] = i_318_;
						anIntArray980[anInt1183] = i_319_;
						anInt1183++;
					} else if (anInt1171 == 1) {
						if ((anInt1173 & 0x4) == 4) {
							aStringArray1184[anInt1183] = (((Client) this).aString1174 + " @cya@" + objectDefinition.aString776);
							anIntArray981[anInt1183] = 376;
							anIntArray982[anInt1183] = i_317_;
							anIntArray979[anInt1183] = i_318_;
							anIntArray980[anInt1183] = i_319_;
							anInt1183++;
						}
					} else {
						if (objectDefinition.aStringArray790 != null) {
							for (int i_322_ = 4; i_322_ >= 0; i_322_--) {
								if (objectDefinition.aStringArray790[i_322_] != null) {
									aStringArray1184[anInt1183] = (objectDefinition.aStringArray790[i_322_]
										+ " @cya@" + objectDefinition.aString776);
									if (i_322_ == 0) {
										anIntArray981[anInt1183] = 35;
									}
									if (i_322_ == 1) {
										anIntArray981[anInt1183] = 389;
									}
									if (i_322_ == 2) {
										anIntArray981[anInt1183] = 888;
									}
									if (i_322_ == 3) {
										anIntArray981[anInt1183] = 892;
									}
									if (i_322_ == 4) {
										anIntArray981[anInt1183] = 1280;
									}
									anIntArray982[anInt1183] = i_317_;
									anIntArray979[anInt1183] = i_318_;
									anIntArray980[anInt1183] = i_319_;
									anInt1183++;
								}
							}
						}
						aStringArray1184[anInt1183] = "Examine @cya@" + objectDefinition.aString776;
						anIntArray981[anInt1183] = 1412;
						anIntArray982[anInt1183] = objectDefinition.anInt773 << 14;
						anIntArray979[anInt1183] = i_318_;
						anIntArray980[anInt1183] = i_319_;
						anInt1183++;
					}
				}
				if (i_320_ == 1) {
					Npc npc = totalNpcs[i_321_];
					if ((((Npc) npc).npc.aByte642 == 1)
						&& (((ObjectInstance) npc).anInt1610 & 0x7f) == 64
						&& (((ObjectInstance) npc).anInt1611 & 0x7f) == 64) {
						for (int i_323_ = 0; i_323_ < npcCount; i_323_++) {
							Npc npc_324_ = (totalNpcs[((Client) this).anIntArray1134[i_323_]]);
							if (npc_324_ != null
								&& (npc_324_ != npc)
								&& (((Npc) npc_324_).npc.aByte642) == 1
								&& ((((ObjectInstance) npc_324_).anInt1610) == ((ObjectInstance) npc).anInt1610)
								&& ((((ObjectInstance) npc_324_).anInt1611) == (((ObjectInstance) npc).anInt1611))) {
								method82((((Npc) npc_324_).npc), i_319_, i_318_,
									(((Client) this).anIntArray1134[i_323_]), (byte) -76);
							}
						}
						for (int i_325_ = 0; i_325_ < playerCount; i_325_++) {
							Player player = (totalPlayers[((Client) this).playerIndices[i_325_]]);
							if (player != null
								&& (((ObjectInstance) player).anInt1610 == ((ObjectInstance) npc).anInt1610)
								&& (((ObjectInstance) player).anInt1611 == (((ObjectInstance) npc).anInt1611))) {
								method38(((Client) this).playerIndices[i_325_], i_319_, i_318_,
									player, 0);
							}
						}
					}
					method82(((Npc) npc).npc, i_319_, i_318_, i_321_, (byte) -76);
				}
				if (i_320_ == 0) {
					Player player = totalPlayers[i_321_];
					if ((((ObjectInstance) player).anInt1610 & 0x7f) == 64
						&& (((ObjectInstance) player).anInt1611 & 0x7f) == 64) {
						for (int i_326_ = 0; i_326_ < npcCount; i_326_++) {
							Npc npc = (totalNpcs[((Client) this).anIntArray1134[i_326_]]);
							if (npc != null
								&& (((Npc) npc).npc.aByte642) == 1
								&& (((ObjectInstance) npc).anInt1610 == ((ObjectInstance) player).anInt1610)
								&& (((ObjectInstance) npc).anInt1611 == (((ObjectInstance) player).anInt1611))) {
								method82((((Npc) npc).npc), i_319_, i_318_,
									(((Client) this).anIntArray1134[i_326_]), (byte) -76);
							}
						}
						for (int i_327_ = 0; i_327_ < playerCount; i_327_++) {
							Player player_328_ = (totalPlayers[((Client) this).playerIndices[i_327_]]);
							if (player_328_ != null
								&& (player_328_ != player)
								&& ((((ObjectInstance) player_328_).anInt1610) == ((ObjectInstance) player).anInt1610)
								&& ((((ObjectInstance) player_328_).anInt1611) == (((ObjectInstance) player).anInt1611))) {
								method38(((Client) this).playerIndices[i_327_], i_319_, i_318_,
									player_328_, 0);
							}
						}
					}
					method38(i_321_, i_319_, i_318_, player, 0);
				}
				if (i_320_ == 3) {
					Deque deque = (aDequeArrayArrayArray1323[anInt1091][i_318_][i_319_]);
					if (deque != null) {
						for (Class50_Sub1_Sub4_Sub1 class50_sub1_sub4_sub1 = ((Class50_Sub1_Sub4_Sub1) deque
							.method159(false)); class50_sub1_sub4_sub1 != null; class50_sub1_sub4_sub1 = ((Class50_Sub1_Sub4_Sub1) deque
							.method161(173))) {
							ItemDefinition itemDefinition = ItemDefinition
								.method212(class50_sub1_sub4_sub1.anInt1550);
							if (anInt1146 == 1) {
								aStringArray1184[anInt1183] = ("Use " + ((Client) this).aString1150
									+ " with @lre@" + itemDefinition.examine);
								anIntArray981[anInt1183] = 100;
								anIntArray982[anInt1183] = class50_sub1_sub4_sub1.anInt1550;
								anIntArray979[anInt1183] = i_318_;
								anIntArray980[anInt1183] = i_319_;
								anInt1183++;
							} else if (anInt1171 == 1) {
								if ((anInt1173 & 0x1) == 1) {
									aStringArray1184[anInt1183] = (((Client) this).aString1174
										+ " @lre@" + itemDefinition.examine);
									anIntArray981[anInt1183] = 199;
									anIntArray982[anInt1183] = class50_sub1_sub4_sub1.anInt1550;
									anIntArray979[anInt1183] = i_318_;
									anIntArray980[anInt1183] = i_319_;
									anInt1183++;
								}
							} else {
								for (int i_329_ = 4; i_329_ >= 0; i_329_--) {
									if (itemDefinition.aStringArray338 != null
										&& (itemDefinition.aStringArray338[i_329_] != null)) {
										aStringArray1184[anInt1183] = (itemDefinition.aStringArray338[i_329_]
											+ " @lre@" + itemDefinition.examine);
										if (i_329_ == 0) {
											anIntArray981[anInt1183] = 68;
										}
										if (i_329_ == 1) {
											anIntArray981[anInt1183] = 26;
										}
										if (i_329_ == 2) {
											anIntArray981[anInt1183] = 684;
										}
										if (i_329_ == 3) {
											anIntArray981[anInt1183] = 930;
										}
										if (i_329_ == 4) {
											anIntArray981[anInt1183] = 270;
										}
										anIntArray982[anInt1183] = class50_sub1_sub4_sub1.anInt1550;
										anIntArray979[anInt1183] = i_318_;
										anIntArray980[anInt1183] = i_319_;
										anInt1183++;
									} else if (i_329_ == 2) {
										aStringArray1184[anInt1183] = ("Take @lre@" + itemDefinition.examine);
										anIntArray981[anInt1183] = 684;
										anIntArray982[anInt1183] = class50_sub1_sub4_sub1.anInt1550;
										anIntArray979[anInt1183] = i_318_;
										anIntArray980[anInt1183] = i_319_;
										anInt1183++;
									}
								}
								aStringArray1184[anInt1183] = "Examine @lre@"
									+ itemDefinition.examine;
								anIntArray981[anInt1183] = 1564;
								anIntArray982[anInt1183] = class50_sub1_sub4_sub1.anInt1550;
								anIntArray979[anInt1183] = i_318_;
								anIntArray980[anInt1183] = i_319_;
								anInt1183++;
							}
						}
					}
				}
			}
		}
	}

	public final void method44(boolean bool, int i) {
		if (bool) {
			Interface.method200(Client.aBoolean1190, i);
		}
	}

	private final void method45(int i, int i_330_, int i_331_, int i_332_, int i_333_, int i_334_,
		byte i_335_, int i_336_) {
		if (i_335_ != aByte1066) {
			anInt1175 = -380;
		}
		if (i_330_ >= 1 && i_332_ >= 1 && i_330_ <= 102 && i_332_ <= 102) {
			if (!Client.aBoolean926 || i_333_ == anInt1091) {
				int i_337_ = 0;
				int i_338_ = -1;
				boolean bool = false;
				boolean bool_339_ = false;
				if (i_336_ == 0) {
					i_337_ = aClass22_1164.method267(i_333_, i_330_, i_332_);
				}
				if (i_336_ == 1) {
					i_337_ = aClass22_1164.method268(i_330_, (byte) 4, i_333_, i_332_);
				}
				if (i_336_ == 2) {
					i_337_ = aClass22_1164.method269(i_333_, i_330_, i_332_);
				}
				if (i_336_ == 3) {
					i_337_ = aClass22_1164.method270(i_333_, i_330_, i_332_);
				}
				if (i_337_ != 0) {
					int i_340_ = aClass22_1164.method271(i_333_, i_330_, i_332_, i_337_);
					i_338_ = i_337_ >> 14 & 0x7fff;
					int i_341_ = i_340_ & 0x1f;
					int i_342_ = i_340_ >> 6;
					if (i_336_ == 0) {
						aClass22_1164.method258(i_332_, i_333_, i_330_, true);
						ObjectDefinition objectDefinition = ObjectDefinition.method434(i_338_);
						if (objectDefinition.aBoolean810) {
							aCollisionMapArray1260[i_333_].method427(i_342_, i_330_, 0, i_332_,
								i_341_, objectDefinition.aBoolean809);
						}
					}
					if (i_336_ == 1) {
						aClass22_1164.method259(false, i_330_, i_332_, i_333_);
					}
					if (i_336_ == 2) {
						aClass22_1164.method260(i_332_, i_333_, -779, i_330_);
						ObjectDefinition objectDefinition = ObjectDefinition.method434(i_338_);
						if (i_330_ + objectDefinition.anInt801 > 103
							|| i_332_ + objectDefinition.anInt801 > 103
							|| i_330_ + objectDefinition.anInt775 > 103
							|| i_332_ + objectDefinition.anInt775 > 103) {
							return;
						}
						if (objectDefinition.aBoolean810) {
							aCollisionMapArray1260[i_333_].method428(anInt1055, i_332_, i_330_,
								i_342_, objectDefinition.anInt775, objectDefinition.aBoolean809,
								objectDefinition.anInt801);
						}
					}
					if (i_336_ == 3) {
						aClass22_1164.method261(i_330_, i_332_, true, i_333_);
						ObjectDefinition objectDefinition = ObjectDefinition.method434(i_338_);
						if (objectDefinition.aBoolean810 && objectDefinition.aBoolean759) {
							aCollisionMapArray1260[i_333_].method430(i_330_, (byte) -122, i_332_);
						}
					}
				}
				if (i_331_ >= 0) {
					int i_343_ = i_333_;
					if (i_343_ < 3 && ((aByteArrayArrayArray1125[1][i_330_][i_332_] & 0x2) == 2)) {
						i_343_++;
					}
					Class8.method165(i_331_, i_343_, i_334_, i_332_,
						aCollisionMapArray1260[i_333_], i, i_330_, 0, i_333_, aClass22_1164,
						anIntArrayArrayArray891);
				}
			}
		}
	}

	private final void method46(int i, byte i_344_, Packet packet) {
		packet.initBitAccess();
		int i_345_ = packet.readBits(8);
		if (i_344_ != aByte1317) {
			anInt1281 = -460;
		}
		if (i_345_ < npcCount) {
			for (int i_346_ = i_345_; i_346_ < npcCount; i_346_++) {
				((Client) this).anIntArray1295[anInt1294++] = ((Client) this).anIntArray1134[i_346_];
			}
		}
		if (i_345_ > npcCount) {
			Signlink.reporterror(aString1092 + " Too many npcs");
			throw new RuntimeException("eek");
		}
		npcCount = 0;
		for (int i_347_ = 0; i_347_ < i_345_; i_347_++) {
			int i_348_ = ((Client) this).anIntArray1134[i_347_];
			Npc npc = totalNpcs[i_348_];
			int i_349_ = packet.readBits(1);
			if (i_349_ == 0) {
				((Client) this).anIntArray1134[npcCount++] = i_348_;
				((ObjectInstance) npc).anInt1585 = Client.anInt1325;
			} else {
				int i_350_ = packet.readBits(2);
				if (i_350_ == 0) {
					((Client) this).anIntArray1134[npcCount++] = i_348_;
					((ObjectInstance) npc).anInt1585 = Client.anInt1325;
					anIntArray974[anInt973++] = i_348_;
				} else if (i_350_ == 1) {
					((Client) this).anIntArray1134[npcCount++] = i_348_;
					((ObjectInstance) npc).anInt1585 = Client.anInt1325;
					int i_351_ = packet.readBits(3);
					npc.method577(false, i_351_, -808);
					int i_352_ = packet.readBits(1);
					if (i_352_ == 1) {
						anIntArray974[anInt973++] = i_348_;
					}
				} else if (i_350_ == 2) {
					((Client) this).anIntArray1134[npcCount++] = i_348_;
					((ObjectInstance) npc).anInt1585 = Client.anInt1325;
					int i_353_ = packet.readBits(3);
					npc.method577(true, i_353_, -808);
					int i_354_ = packet.readBits(3);
					npc.method577(true, i_354_, -808);
					int i_355_ = packet.readBits(1);
					if (i_355_ == 1) {
						anIntArray974[anInt973++] = i_348_;
					}
				} else if (i_350_ == 3) {
					((Client) this).anIntArray1295[anInt1294++] = i_348_;
				}
			}
		}
	}

	public final void sendMessage(String name, String message, int inputId) {
		if (inputId == 0 && anInt1191 != -1) {
			aString1058 = message;
			anInt28 = 0;
		}
		if (anInt988 == -1) {
			aBoolean1240 = true;
		}
		for (int i_358_ = 99; i_358_ > 0; i_358_--) {
			anIntArray1296[i_358_] = anIntArray1296[i_358_ - 1];
			aStringArray1297[i_358_] = aStringArray1297[i_358_ - 1];
			aStringArray1298[i_358_] = aStringArray1298[i_358_ - 1];
		}
		// dummy byte i
		// if (i != aByte901) {
		// anInt1140 = cryption.getNextKey();
		// }
		anIntArray1296[0] = inputId;
		aStringArray1297[0] = name;
		aStringArray1298[0] = message;
	}

	private final void method48(Packet packet, boolean bool, int i) {
		aBoolean1137 &= bool;
		anInt1294 = 0;
		anInt973 = 0;
		method46(i, (byte) -58, packet);
		method132(packet, i, false);
		method62(packet, i, 838);
		for (int i_359_ = 0; i_359_ < anInt1294; i_359_++) {
			int i_360_ = ((Client) this).anIntArray1295[i_359_];
			if (((ObjectInstance) totalNpcs[i_360_]).anInt1585 != Client.anInt1325) {
				((Npc) totalNpcs[i_360_]).npc = null;
				totalNpcs[i_360_] = null;
			}
		}
		if (packet.offset != i) {
			Signlink.reporterror(aString1092 + " size mismatch in getnpcpos - pos:" + packet.offset
				+ " psize:" + i);
			throw new RuntimeException("eek");
		}
		for (int i_361_ = 0; i_361_ < npcCount; i_361_++) {
			if ((totalNpcs[((Client) this).anIntArray1134[i_361_]]) == null) {
				Signlink.reporterror(aString1092 + " null entry in npc list - pos:" + i_361_
					+ " size:" + npcCount);
				throw new RuntimeException("eek");
			}
		}
	}

	public final void method49(int i) {
		ObjectDefinition.aCache_779.method347();
		ObjectDefinition.aCache_762.method347();
		if (i <= 0) {
			for (int i_362_ = 1; i_362_ > 0; i_362_++) {
				/* empty */
			}
		}
		NpcDefinition.npcCache.method347();
		ItemDefinition.aCache_337.method347();
		ItemDefinition.aCache_346.method347();
		Player.aCache_1761.method347();
		SpotAnimation.aCache_566.method347();
	}

	public final void method50(boolean bool) {
		Signlink.midiplay = false;
		if (bool) {
			anInt1119 = 466;
		}
		Signlink.midifade = 0;
		Signlink.midi = "stop";
	}

	public final void method51(boolean bool) {
		Class50_Sub1_Sub4_Sub2 class50_sub1_sub4_sub2 = (Class50_Sub1_Sub4_Sub2) aDeque_1282
			.method158();
		if (bool) {
			anInt1328 = 153;
		}
		for (/**/; class50_sub1_sub4_sub2 != null; class50_sub1_sub4_sub2 = (Class50_Sub1_Sub4_Sub2) aDeque_1282
			.method160(1)) {
			if (class50_sub1_sub4_sub2.anInt1554 != anInt1091
				|| Client.anInt1325 > class50_sub1_sub4_sub2.anInt1566) {
				class50_sub1_sub4_sub2.method453();
			} else if (Client.anInt1325 >= class50_sub1_sub4_sub2.anInt1565) {
				if (class50_sub1_sub4_sub2.anInt1560 > 0) {
					Npc npc = (totalNpcs[class50_sub1_sub4_sub2.anInt1560 - 1]);
					if (npc != null && ((ObjectInstance) npc).anInt1610 >= 0
						&& ((ObjectInstance) npc).anInt1610 < 13312
						&& ((ObjectInstance) npc).anInt1611 >= 0
						&& ((ObjectInstance) npc).anInt1611 < 13312) {
						class50_sub1_sub4_sub2
							.method573(
								((ObjectInstance) npc).anInt1610,
								((ObjectInstance) npc).anInt1611,
								(method110((((ObjectInstance) npc).anInt1611),
									(((ObjectInstance) npc).anInt1610), (byte) 9,
									class50_sub1_sub4_sub2.anInt1554) - class50_sub1_sub4_sub2.anInt1579),
								Client.anInt1325, 0);
					}
				}
				if (class50_sub1_sub4_sub2.anInt1560 < 0) {
					int i = -class50_sub1_sub4_sub2.anInt1560 - 1;
					Player player;
					if (i == anInt961) {
						player = Client.myPlayer;
					} else {
						player = totalPlayers[i];
					}
					if (player != null && ((ObjectInstance) player).anInt1610 >= 0
						&& ((ObjectInstance) player).anInt1610 < 13312
						&& ((ObjectInstance) player).anInt1611 >= 0
						&& ((ObjectInstance) player).anInt1611 < 13312) {
						class50_sub1_sub4_sub2
							.method573(
								((ObjectInstance) player).anInt1610,
								((ObjectInstance) player).anInt1611,
								(method110((((ObjectInstance) player).anInt1611),
									(((ObjectInstance) player).anInt1610), (byte) 9,
									class50_sub1_sub4_sub2.anInt1554) - class50_sub1_sub4_sub2.anInt1579),
								Client.anInt1325, 0);
					}
				}
				class50_sub1_sub4_sub2.method574(anInt951, false);
				aClass22_1164.method252(-1, class50_sub1_sub4_sub2,
					(int) class50_sub1_sub4_sub2.aDouble1555,
					(int) class50_sub1_sub4_sub2.aDouble1557, false, 0, anInt1091, 60,
					(int) class50_sub1_sub4_sub2.aDouble1556, class50_sub1_sub4_sub2.anInt1562);
			}
		}
		Client.anInt1168++;
		if (Client.anInt1168 > 51) {
			Client.anInt1168 = 0;
			aPacket_964.putOpcode(248);
		}
	}

	public final void method52(boolean bool) {
		aIndexedSprite_1292 = new IndexedSprite(aArchive_888, "titlebox", 0);
		aIndexedSprite_1293 = new IndexedSprite(aArchive_888, "titlebutton", 0);
		aIndexedSpriteArray1117 = new IndexedSprite[12];
		if (bool) {
			method6();
		}
		for (int i = 0; i < 12; i++) {
			aIndexedSpriteArray1117[i] = new IndexedSprite(aArchive_888, "runes", i);
		}
		aSprite_1017 = new Sprite(128, 265);
		aSprite_1018 = new Sprite(128, 265);
		for (int i = 0; i < 33920; i++) {
			aSprite_1017.pixels[i] = aGraphicsBuffer_1201.anIntArray392[i];
		}
		for (int i = 0; i < 33920; i++) {
			aSprite_1018.pixels[i] = aGraphicsBuffer_1202.anIntArray392[i];
		}
		anIntArray1311 = new int[256];
		for (int i = 0; i < 64; i++) {
			anIntArray1311[i] = i * 262144;
		}
		for (int i = 0; i < 64; i++) {
			anIntArray1311[i + 64] = 16711680 + i * 1024;
		}
		for (int i = 0; i < 64; i++) {
			anIntArray1311[i + 128] = 16776960 + i * 4;
		}
		for (int i = 0; i < 64; i++) {
			anIntArray1311[i + 192] = 16777215;
		}
		anIntArray1312 = new int[256];
		for (int i = 0; i < 64; i++) {
			anIntArray1312[i] = i * 1024;
		}
		for (int i = 0; i < 64; i++) {
			anIntArray1312[i + 64] = 65280 + i * 4;
		}
		for (int i = 0; i < 64; i++) {
			anIntArray1312[i + 128] = 65535 + i * 262144;
		}
		for (int i = 0; i < 64; i++) {
			anIntArray1312[i + 192] = 16777215;
		}
		anIntArray1313 = new int[256];
		for (int i = 0; i < 64; i++) {
			anIntArray1313[i] = i * 4;
		}
		for (int i = 0; i < 64; i++) {
			anIntArray1313[i + 64] = 255 + i * 262144;
		}
		for (int i = 0; i < 64; i++) {
			anIntArray1313[i + 128] = 16711935 + i * 1024;
		}
		for (int i = 0; i < 64; i++) {
			anIntArray1313[i + 192] = 16777215;
		}
		anIntArray1310 = new int[256];
		anIntArray1176 = new int[32768];
		anIntArray1177 = new int[32768];
		method83(null, 0);
		anIntArray1084 = new int[32768];
		anIntArray1085 = new int[32768];
		drawLoadingText(10, "Connecting to fileserver");
		if (!aBoolean1243) {
			aBoolean1314 = true;
			aBoolean1243 = true;
			method12(this, 2);
		}
	}

	public final void method53(long l, int i) {
		if (l != 0L) {
			for (int i_363_ = 0; i_363_ < friendCount; i_363_++) {
				if (friendNameForLong[i_363_] == l) {
					friendCount--;
					drawInventoryRequest = true;
					for (int i_364_ = i_363_; i_364_ < friendCount; i_364_++) {
						friendNames[i_364_] = friendNames[i_364_ + 1];
						friendNodeIds[i_364_] = friendNodeIds[i_364_ + 1];
						friendNameForLong[i_364_] = friendNameForLong[i_364_ + 1];
					}
					aPacket_964.putOpcode(141);
					aPacket_964.putLong(l);
					break;
				}
			}
			packetSize += i;
		}
	}

	public final void method54(int i) {
		if (anInt1113 == 0) {
			int i_365_ = anInt28;
			if (i != 0) {
				opcode = inputStream.getUByte();
			}
			if (anInt1171 == 1 && anInt29 >= 516 && anInt30 >= 160 && anInt29 <= 765
				&& anInt30 <= 205) {
				i_365_ = 0;
			}
			do {
				if (aBoolean1065) {
					if (i_365_ != 1) {
						int i_366_ = anInt22;
						int i_367_ = anInt23;
						if (anInt1304 == 0) {
							i_366_ -= 4;
							i_367_ -= 4;
						}
						if (anInt1304 == 1) {
							i_366_ -= 553;
							i_367_ -= 205;
						}
						if (anInt1304 == 2) {
							i_366_ -= 17;
							i_367_ -= 357;
						}
						if (i_366_ < anInt1305 - 10 || i_366_ > anInt1305 + anInt1307 + 10
							|| i_367_ < anInt1306 - 10 || i_367_ > anInt1306 + anInt1308 + 10) {
							aBoolean1065 = false;
							if (anInt1304 == 1) {
								drawInventoryRequest = true;
							}
							if (anInt1304 == 2) {
								aBoolean1240 = true;
							}
						}
					}
					if (i_365_ == 1) {
						int i_368_ = anInt1305;
						int i_369_ = anInt1306;
						int i_370_ = anInt1307;
						int i_371_ = anInt29;
						int i_372_ = anInt30;
						if (anInt1304 == 0) {
							i_371_ -= 4;
							i_372_ -= 4;
						}
						if (anInt1304 == 1) {
							i_371_ -= 553;
							i_372_ -= 205;
						}
						if (anInt1304 == 2) {
							i_371_ -= 17;
							i_372_ -= 357;
						}
						int i_373_ = -1;
						for (int i_374_ = 0; i_374_ < anInt1183; i_374_++) {
							int i_375_ = i_369_ + 31 + (anInt1183 - 1 - i_374_) * 15;
							if (i_371_ > i_368_ && i_371_ < i_368_ + i_370_ && i_372_ > i_375_ - 13
								&& i_372_ < i_375_ + 3) {
								i_373_ = i_374_;
							}
						}
						if (i_373_ != -1) {
							method120(i_373_, 8);
						}
						aBoolean1065 = false;
						if (anInt1304 == 1) {
							drawInventoryRequest = true;
						}
						if (anInt1304 == 2) {
							aBoolean1240 = true;
						}
					}
				} else {
					if (i_365_ == 1 && anInt1183 > 0) {
						int i_376_ = anIntArray981[anInt1183 - 1];
						if (i_376_ == 9 || i_376_ == 225 || i_376_ == 444 || i_376_ == 564
							|| i_376_ == 894 || i_376_ == 961 || i_376_ == 399 || i_376_ == 324
							|| i_376_ == 227 || i_376_ == 891 || i_376_ == 52 || i_376_ == 1094) {
							int i_377_ = anIntArray979[anInt1183 - 1];
							int i_378_ = anIntArray980[anInt1183 - 1];
							Interface iComponent = Interface.method195(i_378_);
							if (iComponent.aBoolean274 || iComponent.aBoolean217) {
								aBoolean1155 = false;
								anInt1269 = 0;
								anInt1111 = i_378_;
								anInt1112 = i_377_;
								anInt1113 = 2;
								anInt1114 = anInt29;
								anInt1115 = anInt30;
								if (Interface.method195(i_378_).anInt248 == anInt1169) {
									anInt1113 = 1;
								}
								if (Interface.method195(i_378_).anInt248 == anInt988) {
									anInt1113 = 3;
								}
								break;
							}
						}
					}
					if (i_365_ == 1 && (anInt1300 == 1 || method126(anInt1183 - 1, aByte1161))
						&& anInt1183 > 2) {
						i_365_ = 2;
					}
					if (i_365_ == 1 && anInt1183 > 0) {
						method120(anInt1183 - 1, 8);
					}
					if (i_365_ != 2 || anInt1183 <= 0) {
						break;
					}
					method108(811);
				}
				break;
			} while (false);
		}
	}

	public final void method55(int i, Sprite sprite, int i_379_, int i_380_) {
		int i_381_ = i_380_ * i_380_ + i * i;
		while (i_379_ >= 0) {
			opcode = -1;
		}
		if (i_381_ > 4225 && i_381_ < 90000) {
			int i_382_ = anInt1252 + anInt916 & 0x7ff;
			int i_383_ = Model.anIntArray1710[i_382_];
			int i_384_ = Model.anIntArray1711[i_382_];
			i_383_ = i_383_ * 256 / (anInt1233 + 256);
			i_384_ = i_384_ * 256 / (anInt1233 + 256);
			int i_385_ = i * i_383_ + i_380_ * i_384_ >> 16;
			int i_386_ = i * i_384_ - i_380_ * i_383_ >> 16;
			double d = Math.atan2((double) i_385_, (double) i_386_);
			int i_387_ = (int) (Math.sin(d) * 63.0);
			int i_388_ = (int) (Math.cos(d) * 57.0);
			mapedge.method477(256, 15, i_387_ + 94 + 4 - 10, 15, 20, anInt1119, 20, d,
				83 - i_388_ - 20);
		} else {
			method130(i, true, sprite, i_380_);
		}
	}

	public final void method56(boolean bool, int i, int i_389_, int i_390_, int i_391_, int i_392_) {
		aIndexedSprite_1095.method501(i_392_, i_389_);
		aIndexedSprite_1096.method501(i_392_ + i_390_ - 16, i_389_);
		Renderer2D.method460(i_390_ - 32, i_392_ + 16, anInt931, (byte) -24, 16, i_389_);
		int i_393_ = (i_390_ - 32) * i_390_ / i_391_;
		if (i_393_ < 8) {
			i_393_ = 8;
		}
		int i_394_ = (i_390_ - 32 - i_393_) * i / (i_391_ - i_390_);
		Renderer2D.method460(i_393_, i_392_ + 16 + i_394_, anInt1080, (byte) -24, 16, i_389_);
		Renderer2D.method465(i_389_, anInt1135, i_393_, false, i_392_ + 16 + i_394_);
		Renderer2D.method465(i_389_ + 1, anInt1135, i_393_, false, i_392_ + 16 + i_394_);
		if (!bool) {
			anInt921 = -136;
		}
		Renderer2D.method463(i_389_, anInt1135, i_392_ + 16 + i_394_, 16, true);
		Renderer2D.method463(i_389_, anInt1135, i_392_ + 17 + i_394_, 16, true);
		Renderer2D.method465(i_389_ + 15, anInt1287, i_393_, false, i_392_ + 16 + i_394_);
		Renderer2D.method465(i_389_ + 14, anInt1287, i_393_ - 1, false, i_392_ + 17 + i_394_);
		Renderer2D.method463(i_389_, anInt1287, i_392_ + 15 + i_394_ + i_393_, 16, true);
		Renderer2D.method463(i_389_ + 1, anInt1287, i_392_ + 14 + i_394_ + i_393_, 15, true);
	}

	public final void method57(int i, boolean bool) {
		i = 26 / i;
		for (int i_395_ = 0; i_395_ < npcCount; i_395_++) {
			Npc npc = (totalNpcs[((Client) this).anIntArray1134[i_395_]]);
			int i_396_ = (((Client) this).anIntArray1134[i_395_] << 14) + 536870912;
			if (npc != null && npc.method576(0) && (((Npc) npc).npc.aBoolean644) == bool
				&& ((Npc) npc).npc.method371(-993)) {
				int i_397_ = ((((ObjectInstance) npc).anInt1610) >> 7);
				int i_398_ = ((((ObjectInstance) npc).anInt1611) >> 7);
				if (i_397_ >= 0 && i_397_ < 104 && i_398_ >= 0 && i_398_ < 104) {
					if ((((ObjectInstance) npc).anInt1601) == 1
						&& (((ObjectInstance) npc).anInt1610 & 0x7f) == 64
						&& (((ObjectInstance) npc).anInt1611 & 0x7f) == 64) {
						if (anIntArrayArray886[i_397_][i_398_] == anInt1138) {
							continue;
						}
						anIntArrayArray886[i_397_][i_398_] = anInt1138;
					}
					if (!((Npc) npc).npc.aBoolean631) {
						i_396_ -= -2147483648;
					}
					aClass22_1164.method252(
						i_396_,
						npc,
						((ObjectInstance) npc).anInt1610,
						method110(((ObjectInstance) npc).anInt1611,
							((ObjectInstance) npc).anInt1610, (byte) 9, anInt1091),
						((ObjectInstance) npc).aBoolean1592, 0, anInt1091,
						(((ObjectInstance) npc).anInt1601 - 1) * 64 + 60,
						((ObjectInstance) npc).anInt1611,
						((ObjectInstance) npc).anInt1612);
				}
			}
		}
	}

	public final void method58(int i, int i_399_) {
		Signlink.wavevol = i_399_;
		if (i <= 0) {
			anInt1051 = 57;
		}
	}

	public final void method59(int i) {
		if (anInt873 > 0) {
			method124(true);
		} else {
			method125(-332, "Please wait - attempting to reestablish", "Connection lost");
			anInt1050 = 0;
			if (i != 1) {
				Client.aBoolean1242 = !Client.aBoolean1242;
			}
			anInt1120 = 0;
			Socket socket = this.socket;
			aBoolean1137 = false;
			anInt850 = 0;
			method79(aString1092, aString1093, true);
			if (!aBoolean1137) {
				method124(true);
			}
			try {
				socket.method224();
			} catch (Exception exception) {
				/* empty */
			}
		}
	}

	public final boolean method60(int i, Interface iComponent) {
		int i_400_ = iComponent.anInt242;
		if (i <= 0) {
			opcode = -1;
		}
		if (anInt860 == 2) {
			if (i_400_ == 201) {
				aBoolean1240 = true;
				anInt1244 = 0;
				aBoolean866 = true;
				aString1026 = "";
				anInt1221 = 1;
				aString937 = "Enter name of friend to add to list";
			}
			if (i_400_ == 202) {
				aBoolean1240 = true;
				anInt1244 = 0;
				aBoolean866 = true;
				aString1026 = "";
				anInt1221 = 2;
				aString937 = "Enter name of friend to delete from list";
			}
		}
		if (i_400_ == 205) {
			anInt873 = 250;
			return true;
		}
		if (i_400_ == 501) {
			aBoolean1240 = true;
			anInt1244 = 0;
			aBoolean866 = true;
			aString1026 = "";
			anInt1221 = 4;
			aString937 = "Enter name of player to add to list";
		}
		if (i_400_ == 502) {
			aBoolean1240 = true;
			anInt1244 = 0;
			aBoolean866 = true;
			aString1026 = "";
			anInt1221 = 5;
			aString937 = "Enter name of player to delete from list";
		}
		if (i_400_ >= 300 && i_400_ <= 313) {
			int i_401_ = (i_400_ - 300) / 2;
			int i_402_ = i_400_ & 0x1;
			int i_403_ = anIntArray1326[i_401_];
			if (i_403_ != -1) {
				do {
					if (i_402_ == 0 && --i_403_ < 0) {
						i_403_ = IdentityKit.anInt814 - 1;
					}
					if (i_402_ == 1 && ++i_403_ >= IdentityKit.anInt814) {
						i_403_ = 0;
					}
				} while (IdentityKit.appearances[i_403_].aBoolean821
					|| (IdentityKit.appearances[i_403_].anInt816 != i_401_ + (aBoolean1144 ? 0 : 7)));
				anIntArray1326[i_401_] = i_403_;
				aBoolean1277 = true;
			}
		}
		if (i_400_ >= 314 && i_400_ <= 323) {
			int i_404_ = (i_400_ - 314) / 2;
			int i_405_ = i_400_ & 0x1;
			int i_406_ = anIntArray1099[i_404_];
			if (i_405_ == 0 && --i_406_ < 0) {
				i_406_ = Client.anIntArrayArray1008[i_404_].length - 1;
			}
			if (i_405_ == 1 && ++i_406_ >= Client.anIntArrayArray1008[i_404_].length) {
				i_406_ = 0;
			}
			anIntArray1099[i_404_] = i_406_;
			aBoolean1277 = true;
		}
		if (i_400_ == 324 && !aBoolean1144) {
			aBoolean1144 = true;
			method25(anInt1015);
		}
		if (i_400_ == 325 && aBoolean1144) {
			aBoolean1144 = false;
			method25(anInt1015);
		}
		if (i_400_ == 326) {
			aPacket_964.putOpcode(163);
			aPacket_964.putByte(aBoolean1144 ? 0 : 1);
			for (int i_407_ = 0; i_407_ < 7; i_407_++) {
				aPacket_964.putByte(anIntArray1326[i_407_]);
			}
			for (int i_408_ = 0; i_408_ < 5; i_408_++) {
				aPacket_964.putByte(anIntArray1099[i_408_]);
			}
			return true;
		}
		if (i_400_ == 620) {
			aBoolean1098 = !aBoolean1098;
		}
		if (i_400_ >= 601 && i_400_ <= 613) {
			method15(false);
			if (aString839.length() > 0) {
				aPacket_964.putOpcode(184);
				aPacket_964.putLong(TextUtil.method299(aString839));
				aPacket_964.putByte(i_400_ - 601);
				aPacket_964.putByte(aBoolean1098 ? 1 : 0);
			}
		}
		return false;
	}

	public final Archive method61(int i, int i_409_, String string, int i_410_, int i_411_,
		String string_412_) {
		try {
			byte[] is = null;
			int i_413_ = 5;
			try {
				if (((Client) this).aCacheIndexArray1228[0] != null) {
					is = ((Client) this).aCacheIndexArray1228[0].method292(aByte898, i_411_);
				}
			} catch (Exception exception) {
				/* empty */
			}
			if (is != null) {
				// aCRC32_1088.reset();
				// aCRC32_1088.update(is);
				// int i_414_ = (int) aCRC32_1088.getValue();
				// if (i_414_ != i_409_) {
				// is = null;
				// }
			}
			if (is != null) {
				Archive archive = new Archive(is);
				return archive;
			}
			int i_415_ = 0;
			if (i != 14076) {
				anInt1281 = -343;
			}
			while (is == null) {
				String string_416_ = "Unknown error";
				drawLoadingText(i_410_, "Requesting " + string_412_);
				Object object = null;
				try {
					int i_417_ = 0;
					DataInputStream datainputstream = method31(string + i_409_);
					byte[] is_418_ = new byte[6];
					datainputstream.readFully(is_418_, 0, 6);
					Packet packet = new Packet(is_418_);
					packet.offset = 3;
					int i_419_ = packet.get24BitInt1() + 6;
					int i_420_ = 6;
					is = new byte[i_419_];
					for (int i_421_ = 0; i_421_ < 6; i_421_++) {
						is[i_421_] = is_418_[i_421_];
					}
					while (i_420_ < i_419_) {
						int i_422_ = i_419_ - i_420_;
						if (i_422_ > 1000) {
							i_422_ = 1000;
						}
						int i_423_ = datainputstream.read(is, i_420_, i_422_);
						if (i_423_ < 0) {
							string_416_ = "Length error: " + i_420_ + "/" + i_419_;
							throw new IOException("EOF");
						}
						i_420_ += i_423_;
						int i_424_ = i_420_ * 100 / i_419_;
						if (i_424_ != i_417_) {
							drawLoadingText(i_410_,
								("Loading " + string_412_ + " - " + i_424_ + "%"));
						}
						i_417_ = i_424_;
					}
					datainputstream.close();
					try {
						if (((Client) this).aCacheIndexArray1228[0] != null) {
							((Client) this).aCacheIndexArray1228[0].method293(is.length, true, is,
								i_411_);
						}
					} catch (Exception exception) {
						((Client) this).aCacheIndexArray1228[0] = null;
					}
					if (is != null) {
						// aCRC32_1088.reset();
						// aCRC32_1088.update(is);
						// int i_425_ = (int) aCRC32_1088.getValue();
						// if (i_425_ != i_409_) {
						// is = null;
						// i_415_++;
						// string_416_ = "Checksum error: " + i_425_;
						// }
					}
				} catch (IOException ioexception) {
					if (string_416_.equals("Unknown error")) {
						string_416_ = "Connection error";
					}
					is = null;
				} catch (NullPointerException nullpointerexception) {
					string_416_ = "Null error";
					is = null;
					if (!Signlink.reporterror) {
						return null;
					}
				} catch (ArrayIndexOutOfBoundsException arrayindexoutofboundsexception) {
					string_416_ = "Bounds error";
					is = null;
					if (!Signlink.reporterror) {
						return null;
					}
				} catch (Exception exception) {
					string_416_ = "Unexpected error";
					is = null;
					if (!Signlink.reporterror) {
						return null;
					}
				}
				if (is == null) {
					for (int i_426_ = i_413_; i_426_ > 0; i_426_--) {
						if (i_415_ >= 3) {
							drawLoadingText(i_410_, "Game updated - please reload page");
							i_426_ = 10;
						} else {
							drawLoadingText(i_410_, string_416_ + " - Retrying in " + i_426_);
						}
						try {
							Thread.sleep(1000L);
						} catch (Exception exception) {
							/* empty */
						}
					}
					i_413_ *= 2;
					if (i_413_ > 60) {
						i_413_ = 60;
					}
					aBoolean900 = !aBoolean900;
				}
			}
			Archive archive = new Archive(is);
			return archive;
		} catch (RuntimeException runtimeexception) {
			Signlink.reporterror("12591, " + i + ", " + i_409_ + ", " + string + ", " + i_410_
				+ ", " + i_411_ + ", " + string_412_ + ", " + runtimeexception.toString());
			throw new RuntimeException();
		}
	}

	public final void method10() {
		aBoolean1046 = true;
	}

	private final void method62(Packet packet, int i, int i_427_) {
		i_427_ = 24 / i_427_;
		for (int i_428_ = 0; i_428_ < anInt973; i_428_++) {
			int i_429_ = anIntArray974[i_428_];
			Npc npc = totalNpcs[i_429_];
			int i_430_ = packet.getUByte();
			if ((i_430_ & 0x1) != 0) {
				((Npc) npc).npc = NpcDefinition.method375(packet.getULEShortA1());
				((ObjectInstance) npc).anInt1601 = ((Npc) npc).npc.aByte642;
				((ObjectInstance) npc).anInt1600 = ((Npc) npc).npc.anInt651;
				((ObjectInstance) npc).anInt1619 = ((Npc) npc).npc.anInt645;
				((ObjectInstance) npc).anInt1620 = ((Npc) npc).npc.anInt643;
				((ObjectInstance) npc).anInt1621 = ((Npc) npc).npc.anInt641;
				((ObjectInstance) npc).anInt1622 = ((Npc) npc).npc.anInt633;
				((ObjectInstance) npc).anInt1634 = ((Npc) npc).npc.anInt621;
			}
			if ((i_430_ & 0x40) != 0) {
				((ObjectInstance) npc).anInt1609 = packet.getULEShort();
				if ((((ObjectInstance) npc).anInt1609) == 65535) {
					((ObjectInstance) npc).anInt1609 = -1;
				}
			}
			if ((i_430_ & 0x80) != 0) {
				int i_431_ = packet.getUByteA();
				int i_432_ = packet.getUByteA();
				npc.method578(Client.anInt1325, false, i_431_, i_432_);
				((ObjectInstance) npc).anInt1595 = Client.anInt1325 + 300;
				((ObjectInstance) npc).anInt1596 = packet.getUByte();
				((ObjectInstance) npc).anInt1597 = packet.getUByteS();
			}
			if ((i_430_ & 0x4) != 0) {
				((ObjectInstance) npc).anInt1614 = packet.getUShort();
				int i_433_ = packet.getInt2();
				((ObjectInstance) npc).anInt1618 = i_433_ >> 16;
				((ObjectInstance) npc).anInt1617 = Client.anInt1325 + (i_433_ & 0xffff);
				((ObjectInstance) npc).anInt1615 = 0;
				((ObjectInstance) npc).anInt1616 = 0;
				if ((((ObjectInstance) npc).anInt1617) > Client.anInt1325) {
					((ObjectInstance) npc).anInt1615 = -1;
				}
				if ((((ObjectInstance) npc).anInt1614) == 65535) {
					((ObjectInstance) npc).anInt1614 = -1;
				}
			}
			if ((i_430_ & 0x20) != 0) {
				((ObjectInstance) npc).aString1580 = packet.getString();
				((ObjectInstance) npc).anInt1582 = 100;
			}
			if ((i_430_ & 0x8) != 0) {
				((ObjectInstance) npc).anInt1598 = packet.getULEShortA2();
				((ObjectInstance) npc).anInt1599 = packet.getULEShort();
			}
			if ((i_430_ & 0x2) != 0) {
				int i_434_ = packet.getUShort();
				if (i_434_ == 65535) {
					i_434_ = -1;
				}
				int i_435_ = packet.getUByteS();
				if (i_434_ == ((ObjectInstance) npc).anInt1624 && i_434_ != -1) {
					int i_436_ = Sequence.sequences[i_434_].anInt307;
					if (i_436_ == 1) {
						((ObjectInstance) npc).anInt1625 = 0;
						((ObjectInstance) npc).anInt1626 = 0;
						((ObjectInstance) npc).anInt1627 = i_435_;
						((ObjectInstance) npc).anInt1628 = 0;
					}
					if (i_436_ == 2) {
						((ObjectInstance) npc).anInt1628 = 0;
					}
				} else if (i_434_ == -1
					|| ((ObjectInstance) npc).anInt1624 == -1
					|| (Sequence.sequences[i_434_].anInt301 >= (Sequence.sequences[((ObjectInstance) npc).anInt1624].anInt301))) {
					((ObjectInstance) npc).anInt1624 = i_434_;
					((ObjectInstance) npc).anInt1625 = 0;
					((ObjectInstance) npc).anInt1626 = 0;
					((ObjectInstance) npc).anInt1627 = i_435_;
					((ObjectInstance) npc).anInt1628 = 0;
					((ObjectInstance) npc).anInt1613 = ((ObjectInstance) npc).anInt1633;
				}
			}
			if ((i_430_ & 0x10) != 0) {
				int i_437_ = packet.getUByteS();
				int i_438_ = packet.getUByteS();
				npc.method578(Client.anInt1325, false, i_437_, i_438_);
				((ObjectInstance) npc).anInt1595 = Client.anInt1325 + 300;
				((ObjectInstance) npc).anInt1596 = packet.getUByte();
				((ObjectInstance) npc).anInt1597 = packet.getUByteC();
			}
		}
	}

	private final void method63(int i, int i_439_, Player player, int i_440_, Packet packet) {
		if (i != 2) {
			for (int i_441_ = 1; i_441_ > 0; i_441_++) {
				/* empty */
			}
		}
		if ((i_440_ & 0x8) != 0) {
			int i_442_ = packet.getUShort();
			if (i_442_ == 65535) {
				i_442_ = -1;
			}
			int i_443_ = packet.getUByteS();
			if (i_442_ == ((ObjectInstance) player).anInt1624 && i_442_ != -1) {
				int i_444_ = Sequence.sequences[i_442_].anInt307;
				if (i_444_ == 1) {
					((ObjectInstance) player).anInt1625 = 0;
					((ObjectInstance) player).anInt1626 = 0;
					((ObjectInstance) player).anInt1627 = i_443_;
					((ObjectInstance) player).anInt1628 = 0;
				}
				if (i_444_ == 2) {
					((ObjectInstance) player).anInt1628 = 0;
				}
			} else if (i_442_ == -1
				|| ((ObjectInstance) player).anInt1624 == -1
				|| (Sequence.sequences[i_442_].anInt301 >= (Sequence.sequences[((ObjectInstance) player).anInt1624].anInt301))) {
				((ObjectInstance) player).anInt1624 = i_442_;
				((ObjectInstance) player).anInt1625 = 0;
				((ObjectInstance) player).anInt1626 = 0;
				((ObjectInstance) player).anInt1627 = i_443_;
				((ObjectInstance) player).anInt1628 = 0;
				((ObjectInstance) player).anInt1613 = (((ObjectInstance) player).anInt1633);
			}
		}
		if ((i_440_ & 0x10) != 0) {
			((ObjectInstance) player).aString1580 = packet.getString();
			if (((ObjectInstance) player).aString1580.charAt(0) == '~') {
				((ObjectInstance) player).aString1580 = ((ObjectInstance) player).aString1580
					.substring(1);
				sendMessage(((Player) player).aString1751, ((ObjectInstance) player).aString1580, 2);
			} else if (player == Client.myPlayer) {
				sendMessage(((Player) player).aString1751, ((ObjectInstance) player).aString1580, 2);
			}
			((ObjectInstance) player).anInt1583 = 0;
			((ObjectInstance) player).anInt1593 = 0;
			((ObjectInstance) player).anInt1582 = 150;
		}
		if ((i_440_ & 0x100) != 0) {
			((ObjectInstance) player).anInt1602 = packet.getUByteA();
			((ObjectInstance) player).anInt1604 = packet.getUByteC();
			((ObjectInstance) player).anInt1603 = packet.getUByteS();
			((ObjectInstance) player).anInt1605 = packet.getUByte();
			((ObjectInstance) player).anInt1606 = packet.getUShort() + Client.anInt1325;
			((ObjectInstance) player).anInt1607 = packet.getULEShortA1() + Client.anInt1325;
			((ObjectInstance) player).anInt1608 = packet.getUByte();
			player.method575(-56);
		}
		if ((i_440_ & 0x1) != 0) {
			((ObjectInstance) player).anInt1609 = packet.getULEShortA1();
			if ((((ObjectInstance) player).anInt1609) == 65535) {
				((ObjectInstance) player).anInt1609 = -1;
			}
		}
		if ((i_440_ & 0x2) != 0) {
			((ObjectInstance) player).anInt1598 = packet.getUShort();
			((ObjectInstance) player).anInt1599 = packet.getUShort();
		}
		if ((i_440_ & 0x200) != 0) {
			((ObjectInstance) player).anInt1614 = packet.getULEShortA1();
			int i_445_ = packet.getInt2();
			((ObjectInstance) player).anInt1618 = i_445_ >> 16;
			((ObjectInstance) player).anInt1617 = Client.anInt1325 + (i_445_ & 0xffff);
			((ObjectInstance) player).anInt1615 = 0;
			((ObjectInstance) player).anInt1616 = 0;
			if ((((ObjectInstance) player).anInt1617) > Client.anInt1325) {
				((ObjectInstance) player).anInt1615 = -1;
			}
			if ((((ObjectInstance) player).anInt1614) == 65535) {
				((ObjectInstance) player).anInt1614 = -1;
			}
		}
		if ((i_440_ & 0x4) != 0) {
			int i_446_ = packet.getUByte();
			byte[] is = new byte[i_446_];
			Packet packet_447_ = new Packet(is);
			packet.getBytesC(is, i_446_, 0);
			aPacketArray975[i_439_] = packet_447_;
			player.method583(packet_447_, 0);
		}
		if ((i_440_ & 0x400) != 0) {
			int i_448_ = packet.getUByteA();
			int i_449_ = packet.getUByteS();
			player.method578(Client.anInt1325, false, i_448_, i_449_);
			((ObjectInstance) player).anInt1595 = Client.anInt1325 + 300;
			((ObjectInstance) player).anInt1596 = packet.getUByteC();
			((ObjectInstance) player).anInt1597 = packet.getUByte();
		}
		if ((i_440_ & 0x40) != 0) {
			int i_450_ = packet.getUShort();
			int i_451_ = packet.getUByteC();
			int i_452_ = packet.getUByteA();
			int i_453_ = packet.offset;
			if ((((Player) player).aString1751) != null && (((Player) player).aBoolean1758)) {
				long l = TextUtil.method299(((Player) player).aString1751);
				boolean bool = false;
				if (i_451_ <= 1) {
					for (int i_454_ = 0; i_454_ < anInt855; i_454_++) {
						if (aLongArray1073[i_454_] == l) {
							bool = true;
							break;
						}
					}
				}
				if (!bool && anInt1246 == 0) {
					try {
						aPacket_1131.offset = 0;
						packet.getBytesA((aPacket_1131.payload), i_452_, 0);
						aPacket_1131.offset = 0;
						String string = Class31.method320(0, aPacket_1131, i_452_);
						string = Class45.method394((byte) 0, string);
						((ObjectInstance) player).aString1580 = string;
						((ObjectInstance) player).anInt1583 = i_450_ >> 8;
						((ObjectInstance) player).anInt1593 = i_450_ & 0xff;
						((ObjectInstance) player).anInt1582 = 150;
						if (i_451_ == 2 || i_451_ == 3) {
							sendMessage("@cr2@" + (((Player) player).aString1751), string, 1);
						} else if (i_451_ == 1) {
							sendMessage("@cr1@" + (((Player) player).aString1751), string, 1);
						} else {
							sendMessage(((Player) player).aString1751, string, 2);
						}
					} catch (Exception exception) {
						Signlink.reporterror("cde2");
					}
				}
			}
			packet.offset = i_453_ + i_452_;
		}
		if ((i_440_ & 0x80) != 0) {
			int i_455_ = packet.getUByteS();
			int i_456_ = packet.getUByteC();
			player.method578(Client.anInt1325, false, i_455_, i_456_);
			((ObjectInstance) player).anInt1595 = Client.anInt1325 + 300;
			((ObjectInstance) player).anInt1596 = packet.getUByteS();
			((ObjectInstance) player).anInt1597 = packet.getUByte();
		}
	}

	public final void method64(int i) {
		if (aGraphicsBuffer_1198 == null) {
			aGraphicsBuffer_15 = null;
			aGraphicsBuffer_1159 = null;
			aGraphicsBuffer_1157 = null;
			aGraphicsBuffer_1156 = null;
			aGraphicsBuffer_1158 = null;
			aGraphicsBuffer_1108 = null;
			aGraphicsBuffer_1109 = null;
			aGraphicsBuffer_1110 = null;
			if (i < 0) {
				aGraphicsBuffer_1201 = new GraphicsBuffer(265, method11(), 128);
				Renderer2D.method458(4);
				aGraphicsBuffer_1202 = new GraphicsBuffer(265, method11(), 128);
				Renderer2D.method458(4);
				aGraphicsBuffer_1198 = new GraphicsBuffer(171, method11(), 509);
				Renderer2D.method458(4);
				aGraphicsBuffer_1199 = new GraphicsBuffer(132, method11(), 360);
				Renderer2D.method458(4);
				aGraphicsBuffer_1200 = new GraphicsBuffer(200, method11(), 360);
				Renderer2D.method458(4);
				aGraphicsBuffer_1203 = new GraphicsBuffer(238, method11(), 202);
				Renderer2D.method458(4);
				aGraphicsBuffer_1204 = new GraphicsBuffer(238, method11(), 203);
				Renderer2D.method458(4);
				aGraphicsBuffer_1205 = new GraphicsBuffer(94, method11(), 74);
				Renderer2D.method458(4);
				aGraphicsBuffer_1206 = new GraphicsBuffer(94, method11(), 75);
				Renderer2D.method458(4);
				if (aArchive_888 != null) {
					method139(Client.aBoolean1207);
					method52(false);
				}
				aBoolean1046 = true;
			}
		}
	}

	public final void method6() {
		drawLoadingText(20, "Starting up");
		if (Signlink.sunjava) {
			anInt8 = 5;
		}
		if (Client.aBoolean999) {
			aBoolean1016 = true;
		} else {
			Client.aBoolean999 = true;
			boolean bool = false;
			String string = method37(-42588);
			if (string.endsWith("jagex.com")) {
				bool = true;
			}
			if (string.endsWith("runescape.com")) {
				bool = true;
			}
			if (string.endsWith("192.168.1.2")) {
				bool = true;
			}
			if (string.endsWith("192.168.1.231")) {
				bool = true;
			}
			if (string.endsWith("192.168.1.229")) {
				bool = true;
			}
			if (string.endsWith("192.168.1.228")) {
				bool = true;
			}
			if (string.endsWith("192.168.1.227")) {
				bool = true;
			}
			if (string.endsWith("192.168.1.226")) {
				bool = true;
			}
			if (string.endsWith("192.168.1.224")) {
				bool = true;
			}
			if (string.endsWith("192.168.1.223")) {
				bool = true;
			}
			if (string.endsWith("192.168.1.221")) {
				bool = true;
			}
			if (string.endsWith("127.0.0.1")) {
				bool = true;
			}
			if (!bool) {
				aBoolean1097 = true;
			} else {
				if (Signlink.cache_dat != null) {
					for (int i = 0; i < 5; i++) {
						((Client) this).aCacheIndexArray1228[i] = new CacheIndex(i + 1, 600000,
							Signlink.cache_dat, Signlink.cache_idx[i]);
					}
				}
				try {
					method86();
					aArchive_888 = method61(14076, anIntArray837[1], "title", 25, 1, "title screen");
					aFont_1059 = new Font(false, aArchive_888, -914, "p11_full");
					aFont_1060 = new Font(false, aArchive_888, -914, "p12_full");
					aFont_1061 = new Font(false, aArchive_888, -914, "b12_full");
					aFont_1062 = new Font(true, aArchive_888, -914, "q8_full");
					method139(Client.aBoolean1207);
					method52(false);
					Archive archive = method61(14076, anIntArray837[2], "config", 30, 2, "config");
					Archive archive_457_ = method61(14076, anIntArray837[3], "interface", 35, 3,
						"interface");
					Archive mediaArchive = method61(14076, anIntArray837[4], "media", 40, 4,
						"2d graphics");
					Archive archive_459_ = method61(14076, anIntArray837[6], "textures", 45, 6,
						"textures");
					Archive archive_460_ = method61(14076, anIntArray837[7], "wordenc", 50, 7,
						"chat system");
					Archive archive_461_ = method61(14076, anIntArray837[8], "sounds", 55, 8,
						"sound effects");
					aByteArrayArrayArray1125 = new byte[4][104][104];
					anIntArrayArrayArray891 = new int[4][105][105];
					aClass22_1164 = new Class22(anIntArrayArrayArray891, 104, 4, 104, (byte) 5);
					for (int i = 0; i < 4; i++) {
						aCollisionMapArray1260[i] = new CollisionMap(104, 0, 104);
					}
					aSprite_1122 = new Sprite(512, 512);
					Archive archive_462_ = method61(14076, anIntArray837[5], "versionlist", 60, 5,
						"update list");
					drawLoadingText(60, "Connecting to update server");
					aClass32_Sub1_1291 = new Class32_Sub1();
					aClass32_Sub1_1291.method335(archive_462_, this);
					Class21.method235(aClass32_Sub1_1291.method343(553));
					Model.method585(aClass32_Sub1_1291.method340(0, -31140), aClass32_Sub1_1291);
					if (!Client.aBoolean926) {
						anInt1270 = 0;
						aBoolean1271 = true;
						aClass32_Sub1_1291.method329(2, anInt1270);
						while (aClass32_Sub1_1291.method333() > 0) {
							method77(false);
							try {
								Thread.sleep(100L);
							} catch (Exception exception) {
								/* empty */
							}
							if (aClass32_Sub1_1291.anInt1379 > 3) {
								method19("ondemand");
								return;
							}
						}
					}
					drawLoadingText(65, "Requesting animations");
					int i = aClass32_Sub1_1291.method340(1, -31140);
					for (int i_463_ = 0; i_463_ < i; i_463_++) {
						aClass32_Sub1_1291.method329(1, i_463_);
					}
					while (aClass32_Sub1_1291.method333() > 0) {
						int i_464_ = i - aClass32_Sub1_1291.method333();
						if (i_464_ > 0) {
							drawLoadingText(65, ("Loading animations - " + i_464_ * 100 / i + "%"));
						}
						method77(false);
						try {
							Thread.sleep(100L);
						} catch (Exception exception) {
							/* empty */
						}
						if (aClass32_Sub1_1291.anInt1379 > 3) {
							method19("ondemand");
							return;
						}
					}
					drawLoadingText(70, "Requesting models");
					i = aClass32_Sub1_1291.method340(0, -31140);
					for (int i_465_ = 0; i_465_ < i; i_465_++) {
						int i_466_ = aClass32_Sub1_1291.method325(i_465_, -493);
						if ((i_466_ & 0x1) != 0) {
							aClass32_Sub1_1291.method329(0, i_465_);
						}
					}
					i = aClass32_Sub1_1291.method333();
					while (aClass32_Sub1_1291.method333() > 0) {
						int i_467_ = i - aClass32_Sub1_1291.method333();
						if (i_467_ > 0) {
							drawLoadingText(70, ("Loading models - " + i_467_ * 100 / i + "%"));
						}
						method77(false);
						try {
							Thread.sleep(100L);
						} catch (Exception exception) {
						}
					}
					if (((Client) this).aCacheIndexArray1228[0] != null) {
						drawLoadingText(75, "Requesting maps");
						aClass32_Sub1_1291.method329(3, aClass32_Sub1_1291.method344(0, 47, 48, 0));
						aClass32_Sub1_1291.method329(3, aClass32_Sub1_1291.method344(0, 47, 48, 1));
						aClass32_Sub1_1291.method329(3, aClass32_Sub1_1291.method344(0, 48, 48, 0));
						aClass32_Sub1_1291.method329(3, aClass32_Sub1_1291.method344(0, 48, 48, 1));
						aClass32_Sub1_1291.method329(3, aClass32_Sub1_1291.method344(0, 49, 48, 0));
						aClass32_Sub1_1291.method329(3, aClass32_Sub1_1291.method344(0, 49, 48, 1));
						aClass32_Sub1_1291.method329(3, aClass32_Sub1_1291.method344(0, 47, 47, 0));
						aClass32_Sub1_1291.method329(3, aClass32_Sub1_1291.method344(0, 47, 47, 1));
						aClass32_Sub1_1291.method329(3, aClass32_Sub1_1291.method344(0, 48, 47, 0));
						aClass32_Sub1_1291.method329(3, aClass32_Sub1_1291.method344(0, 48, 47, 1));
						aClass32_Sub1_1291
							.method329(3, aClass32_Sub1_1291.method344(0, 48, 148, 0));
						aClass32_Sub1_1291
							.method329(3, aClass32_Sub1_1291.method344(0, 48, 148, 1));
						i = aClass32_Sub1_1291.method333();
						while (aClass32_Sub1_1291.method333() > 0) {
							int i_468_ = i - aClass32_Sub1_1291.method333();
							if (i_468_ > 0) {
								drawLoadingText(75, ("Loading maps - " + i_468_ * 100 / i + "%"));
							}
							method77(false);
							try {
								Thread.sleep(100L);
							} catch (Exception exception) {
							}
						}
					}
					i = aClass32_Sub1_1291.method340(0, -31140);
					for (int i_469_ = 0; i_469_ < i; i_469_++) {
						int i_470_ = aClass32_Sub1_1291.method325(i_469_, -493);
						byte i_471_ = 0;
						if ((i_470_ & 0x8) != 0) {
							i_471_ = (byte) 10;
						} else if ((i_470_ & 0x20) != 0) {
							i_471_ = (byte) 9;
						} else if ((i_470_ & 0x10) != 0) {
							i_471_ = (byte) 8;
						} else if ((i_470_ & 0x40) != 0) {
							i_471_ = (byte) 7;
						} else if ((i_470_ & 0x80) != 0) {
							i_471_ = (byte) 6;
						} else if ((i_470_ & 0x2) != 0) {
							i_471_ = (byte) 5;
						} else if ((i_470_ & 0x4) != 0) {
							i_471_ = (byte) 4;
						}
						if ((i_470_ & 0x1) != 0) {
							i_471_ = (byte) 3;
						}
						if (i_471_ != 0) {
							aClass32_Sub1_1291.method327(-44, 0, i_471_, i_469_);
						}
					}
					aClass32_Sub1_1291.method332(Client.aBoolean925, (byte) 109);
					if (!Client.aBoolean926) {
						i = aClass32_Sub1_1291.method340(2, -31140);
						for (int i_472_ = 1; i_472_ < i; i_472_++) {
							if (aClass32_Sub1_1291.method328(i_472_, Client.aBoolean963)) {
								aClass32_Sub1_1291.method327(-44, 2, (byte) 1, i_472_);
							}
						}
					}
					i = aClass32_Sub1_1291.method340(0, -31140);
					for (int i_473_ = 0; i_473_ < i; i_473_++) {
						int i_474_ = aClass32_Sub1_1291.method325(i_473_, -493);
						if (i_474_ == 0 && aClass32_Sub1_1291.anInt1350 < 200) {
							aClass32_Sub1_1291.method327(-44, 0, (byte) 1, i_473_);
						}
					}
					drawLoadingText(80, "Unpacking media");
					invback = new IndexedSprite(mediaArchive, "invback", 0);
					chatback = new IndexedSprite(mediaArchive, "chatback", 0);
					mapback = new IndexedSprite(mediaArchive, "mapback", 0);
					backbase1 = new IndexedSprite(mediaArchive, "backbase1", 0);
					backbase2 = new IndexedSprite(mediaArchive, "backbase2", 0);
					backhmid1 = new IndexedSprite(mediaArchive, "backhmid1", 0);
					for (int i_475_ = 0; i_475_ < 13; i_475_++) {
						sideicons[i_475_] = new IndexedSprite(mediaArchive, "sideicons", i_475_);
					}
					compass = new Sprite(mediaArchive, "compass", 0);
					mapedge = new Sprite(mediaArchive, "mapedge", 0);
					mapedge.method469(1790);
					for (int i_476_ = 0; i_476_ < 72; i_476_++) {
						mapscenes[i_476_] = new IndexedSprite(mediaArchive, "mapscene", i_476_);
					}
					for (int i_477_ = 0; i_477_ < 70; i_477_++) {
						mapfunctions[i_477_] = new Sprite(mediaArchive, "mapfunction", i_477_);
					}
					for (int i_478_ = 0; i_478_ < 5; i_478_++) {
						hitmarks[i_478_] = new Sprite(mediaArchive, "hitmarks", i_478_);
					}
					for (int i_479_ = 0; i_479_ < 6; i_479_++) {
						headicons_pk[i_479_] = new Sprite(mediaArchive, "headicons_pk", i_479_);
					}
					for (int i_480_ = 0; i_480_ < 9; i_480_++) {
						headicons_prayer[i_480_] = new Sprite(mediaArchive, "headicons_prayer",
							i_480_);
					}
					for (int i_481_ = 0; i_481_ < 6; i_481_++) {
						headicons_hint[i_481_] = new Sprite(mediaArchive, "headicons_hint", i_481_);
					}
					overlay_multiway = new Sprite(mediaArchive, "overlay_multiway", 0);
					aSprite_1036 = new Sprite(mediaArchive, "mapmarker", 0);
					aSprite_1037 = new Sprite(mediaArchive, "mapmarker", 1);
					for (int i_482_ = 0; i_482_ < 8; i_482_++) {
						aSpriteArray896[i_482_] = new Sprite(mediaArchive, "cross", i_482_);
					}
					aSprite_1192 = new Sprite(mediaArchive, "mapdots", 0);
					aSprite_1193 = new Sprite(mediaArchive, "mapdots", 1);
					aSprite_1194 = new Sprite(mediaArchive, "mapdots", 2);
					aSprite_1195 = new Sprite(mediaArchive, "mapdots", 3);
					aSprite_1196 = new Sprite(mediaArchive, "mapdots", 4);
					aIndexedSprite_1095 = new IndexedSprite(mediaArchive, "scrollbar", 0);
					aIndexedSprite_1096 = new IndexedSprite(mediaArchive, "scrollbar", 1);
					aIndexedSprite_880 = new IndexedSprite(mediaArchive, "redstone1", 0);
					aIndexedSprite_881 = new IndexedSprite(mediaArchive, "redstone2", 0);
					aIndexedSprite_882 = new IndexedSprite(mediaArchive, "redstone3", 0);
					aIndexedSprite_883 = new IndexedSprite(mediaArchive, "redstone1", 0);
					aIndexedSprite_883.method498();
					aIndexedSprite_884 = new IndexedSprite(mediaArchive, "redstone2", 0);
					aIndexedSprite_884.method498();
					aIndexedSprite_983 = new IndexedSprite(mediaArchive, "redstone1", 0);
					aIndexedSprite_983.method499();
					aIndexedSprite_984 = new IndexedSprite(mediaArchive, "redstone2", 0);
					aIndexedSprite_984.method499();
					aIndexedSprite_985 = new IndexedSprite(mediaArchive, "redstone3", 0);
					aIndexedSprite_985.method499();
					aIndexedSprite_986 = new IndexedSprite(mediaArchive, "redstone1", 0);
					aIndexedSprite_986.method498();
					aIndexedSprite_986.method499();
					aIndexedSprite_987 = new IndexedSprite(mediaArchive, "redstone2", 0);
					aIndexedSprite_987.method498();
					aIndexedSprite_987.method499();
					for (int i_483_ = 0; i_483_ < 2; i_483_++) {
						mod_icons[i_483_] = new IndexedSprite(mediaArchive, "mod_icons", i_483_);
					}
					Sprite sprite = new Sprite(mediaArchive, "backleft1", 0);
					aGraphicsBuffer_906 = new GraphicsBuffer(sprite.height, method11(),
						sprite.width);
					sprite.method470(0, 0);
					sprite = new Sprite(mediaArchive, "backleft2", 0);
					aGraphicsBuffer_907 = new GraphicsBuffer(sprite.height, method11(),
						sprite.width);
					sprite.method470(0, 0);
					sprite = new Sprite(mediaArchive, "backright1", 0);
					aGraphicsBuffer_908 = new GraphicsBuffer(sprite.height, method11(),
						sprite.width);
					sprite.method470(0, 0);
					sprite = new Sprite(mediaArchive, "backright2", 0);
					aGraphicsBuffer_909 = new GraphicsBuffer(sprite.height, method11(),
						sprite.width);
					sprite.method470(0, 0);
					sprite = new Sprite(mediaArchive, "backtop1", 0);
					aGraphicsBuffer_910 = new GraphicsBuffer(sprite.height, method11(),
						sprite.width);
					sprite.method470(0, 0);
					sprite = new Sprite(mediaArchive, "backvmid1", 0);
					aGraphicsBuffer_911 = new GraphicsBuffer(sprite.height, method11(),
						sprite.width);
					sprite.method470(0, 0);
					sprite = new Sprite(mediaArchive, "backvmid2", 0);
					aGraphicsBuffer_912 = new GraphicsBuffer(sprite.height, method11(),
						sprite.width);
					sprite.method470(0, 0);
					sprite = new Sprite(mediaArchive, "backvmid3", 0);
					aGraphicsBuffer_913 = new GraphicsBuffer(sprite.height, method11(),
						sprite.width);
					sprite.method470(0, 0);
					sprite = new Sprite(mediaArchive, "backhmid2", 0);
					aGraphicsBuffer_914 = new GraphicsBuffer(sprite.height, method11(),
						sprite.width);
					sprite.method470(0, 0);
					int i_484_ = (int) (Math.random() * 21.0) - 10;
					int i_485_ = (int) (Math.random() * 21.0) - 10;
					int i_486_ = (int) (Math.random() * 21.0) - 10;
					int i_487_ = (int) (Math.random() * 41.0) - 20;
					for (int i_488_ = 0; i_488_ < 100; i_488_++) {
						if (mapfunctions[i_488_] != null) {
							mapfunctions[i_488_].method468(i_486_ + i_487_, i_485_ + i_487_, i_484_
								+ i_487_);
						}
						if (mapscenes[i_488_] != null) {
							mapscenes[i_488_].method500(i_486_ + i_487_, i_485_ + i_487_, i_484_
								+ i_487_);
						}
					}
					drawLoadingText(83, "Unpacking textures");
					Renderer3D.method508(archive_459_, -17551);
					Renderer3D.method512(0.8, (byte) 6);
					Renderer3D.method507((byte) 7, 20);
					drawLoadingText(86, "Unpacking config");
					Sequence.getValues(archive);
					ObjectDefinition.getValues(archive);
					Floor.method207(archive);
					ItemDefinition.method214(archive);
					NpcDefinition.method372(archive);
					IdentityKit.method445(archive, 36135);
					SpotAnimation.getValues(archive);
					Varp.getValues(archive);
					VarBit.method451(archive, 36135);
					ItemDefinition.aBoolean344 = Client.aBoolean925;
					if (!Client.aBoolean926) {
						drawLoadingText(90, "Unpacking sounds");
						byte[] is = archive_461_.method154("sounds.dat", null);
						Packet packet = new Packet(is);
						Class38.method376(packet, 36135);
					}
					drawLoadingText(95, "Unpacking interfaces");
					Font[] class50_sub1_sub1_sub2s = { aFont_1059, aFont_1060, aFont_1061,
						aFont_1062 };
					Interface.method199(class50_sub1_sub1_sub2s, archive_457_, mediaArchive);
					drawLoadingText(100, "Preparing game engine");
					for (int i_489_ = 0; i_489_ < 33; i_489_++) {
						int i_490_ = 999;
						int i_491_ = 0;
						for (int i_492_ = 0; i_492_ < 34; i_492_++) {
							if ((mapback.pixels[(i_492_ + i_489_ * (mapback.width))]) == 0) {
								if (i_490_ == 999) {
									i_490_ = i_492_;
								}
							} else if (i_490_ != 999) {
								i_491_ = i_492_;
								break;
							}
						}
						anIntArray1180[i_489_] = i_490_;
						anIntArray1286[i_489_] = i_491_ - i_490_;
					}
					for (int i_493_ = 5; i_493_ < 156; i_493_++) {
						int i_494_ = 999;
						int i_495_ = 0;
						for (int i_496_ = 25; i_496_ < 172; i_496_++) {
							if ((mapback.pixels[(i_496_ + i_493_ * (mapback.width))]) == 0
								&& (i_496_ > 34 || i_493_ > 34)) {
								if (i_494_ == 999) {
									i_494_ = i_496_;
								}
							} else if (i_494_ != 999) {
								i_495_ = i_496_;
								break;
							}
						}
						anIntArray1019[i_493_ - 5] = i_494_ - 25;
						anIntArray920[i_493_ - 5] = i_495_ - i_494_;
					}
					Renderer3D.method505(503, 7, 765);
					anIntArray1003 = Renderer3D.anIntArray1538;
					Renderer3D.method505(96, 7, 479);
					anIntArray1000 = Renderer3D.anIntArray1538;
					Renderer3D.method505(261, 7, 190);
					anIntArray1001 = Renderer3D.anIntArray1538;
					Renderer3D.method505(334, 7, 512);
					anIntArray1002 = Renderer3D.anIntArray1538;
					int[] is = new int[9];
					for (int i_497_ = 0; i_497_ < 9; i_497_++) {
						int i_498_ = i_497_ * 32 + 128 + 15;
						int i_499_ = i_498_ * 3 + 600;
						int i_500_ = Renderer3D.anIntArray1536[i_498_];
						is[i_497_] = i_499_ * i_500_ >> 16;
					}
					Class22.method277(334, 22845, is, 800, 500, 512);
					Class45.method384(archive_460_);
					((Client) this).aClass7_1248 = new Class7(this, (byte) -116);
					method12(((Client) this).aClass7_1248, 10);
					Class50_Sub1_Sub4_Sub5.aClient1723 = this;
					ObjectDefinition.aClient770 = this;
					NpcDefinition.clientInstance = this;
				} catch (Exception exception) {
					Signlink.reporterror("loaderror " + aString1027 + " " + anInt1322);
					aBoolean1283 = true;
				}
			}
		}
	}

	public final void method65(int i, int i_501_) {
		if (i_501_ < 0) {
			if (!Client.aBoolean926) {
				for (int i_503_ : ((Client) this).anIntArray1290) {
					if (Renderer3D.anIntArray1546[i_503_] >= i) {
						IndexedSprite class50_sub1_sub1_sub3 = (Renderer3D.aIndexedSpriteArray1540[i_503_]);
						int i_504_ = ((class50_sub1_sub1_sub3.width * class50_sub1_sub1_sub3.anInt1519) - 1);
						int i_505_ = class50_sub1_sub1_sub3.width * anInt951 * 2;
						byte[] is = class50_sub1_sub1_sub3.pixels;
						byte[] is_506_ = aByteArray1245;
						for (int i_507_ = 0; i_507_ <= i_504_; i_507_++) {
							is_506_[i_507_] = is[i_507_ - i_505_ & i_504_];
						}
						class50_sub1_sub1_sub3.pixels = is_506_;
						aByteArray1245 = is;
						Renderer3D.method510(i_503_, 9);
					}
				}
			}
		}
	}

	public final void method66(int i, Interface iComponent, int i_508_, int i_509_, int i_510_,
		int i_511_, int i_512_, int i_513_) {
		if (i_512_ == 23658
			&& (iComponent.anInt236 == 0 && iComponent.anIntArray258 != null && !iComponent.aBoolean219)
			&& (i_511_ >= i_510_ && i_513_ >= i && i_511_ <= i_510_ + iComponent.anInt241 && i_513_ <= i
				+ iComponent.anInt238)) {
			int i_514_ = iComponent.anIntArray258.length;
			for (int i_515_ = 0; i_515_ < i_514_; i_515_++) {
				int i_516_ = iComponent.anIntArray232[i_515_] + i_510_;
				int i_517_ = iComponent.anIntArray276[i_515_] + i - i_509_;
				Interface iComponent_518_ = Interface.method195(iComponent.anIntArray258[i_515_]);
				i_516_ += iComponent_518_.anInt228;
				i_517_ += iComponent_518_.anInt259;
				if ((iComponent_518_.anInt254 >= 0 || iComponent_518_.anInt261 != 0)
					&& i_511_ >= i_516_ && i_513_ >= i_517_
					&& i_511_ < i_516_ + iComponent_518_.anInt241
					&& i_513_ < i_517_ + iComponent_518_.anInt238) {
					if (iComponent_518_.anInt254 >= 0) {
						anInt915 = iComponent_518_.anInt254;
					} else {
						anInt915 = iComponent_518_.anInt215;
					}
				}
				if (iComponent_518_.anInt236 == 8 && i_511_ >= i_516_ && i_513_ >= i_517_
					&& i_511_ < i_516_ + iComponent_518_.anInt241
					&& i_513_ < i_517_ + iComponent_518_.anInt238) {
					anInt1315 = iComponent_518_.anInt215;
				}
				if (iComponent_518_.anInt236 == 0) {
					method66(i_517_, iComponent_518_, i_508_, iComponent_518_.anInt231, i_516_,
						i_511_, 23658, i_513_);
					if (iComponent_518_.anInt285 > iComponent_518_.anInt238) {
						method42(iComponent_518_.anInt285, i_517_, iComponent_518_, (byte) 102,
							i_513_, i_508_, i_511_, iComponent_518_.anInt238, i_516_
								+ iComponent_518_.anInt241);
					}
				} else {
					if (iComponent_518_.anInt289 == 1 && i_511_ >= i_516_ && i_513_ >= i_517_
						&& i_511_ < i_516_ + iComponent_518_.anInt241
						&& i_513_ < i_517_ + iComponent_518_.anInt238) {
						boolean bool = false;
						if (iComponent_518_.anInt242 != 0) {
							bool = method23(iComponent_518_, 8);
						}
						if (!bool) {
							aStringArray1184[anInt1183] = iComponent_518_.aString268;
							anIntArray981[anInt1183] = 352;
							anIntArray980[anInt1183] = iComponent_518_.anInt215;
							anInt1183++;
						}
					}
					if (iComponent_518_.anInt289 == 2 && anInt1171 == 0 && i_511_ >= i_516_
						&& i_513_ >= i_517_ && i_511_ < i_516_ + iComponent_518_.anInt241
						&& i_513_ < i_517_ + iComponent_518_.anInt238) {
						String string = iComponent_518_.aString281;
						if (string.indexOf(" ") != -1) {
							string = string.substring(0, string.indexOf(" "));
						}
						aStringArray1184[anInt1183] = string + " @gre@"
							+ iComponent_518_.aString211;
						anIntArray981[anInt1183] = 70;
						anIntArray980[anInt1183] = iComponent_518_.anInt215;
						anInt1183++;
					}
					if (iComponent_518_.anInt289 == 3 && i_511_ >= i_516_ && i_513_ >= i_517_
						&& i_511_ < i_516_ + iComponent_518_.anInt241
						&& i_513_ < i_517_ + iComponent_518_.anInt238) {
						aStringArray1184[anInt1183] = "Close";
						if (i_508_ == 3) {
							anIntArray981[anInt1183] = 55;
						} else {
							anIntArray981[anInt1183] = 639;
						}
						anIntArray980[anInt1183] = iComponent_518_.anInt215;
						anInt1183++;
					}
					if (iComponent_518_.anInt289 == 4 && i_511_ >= i_516_ && i_513_ >= i_517_
						&& i_511_ < i_516_ + iComponent_518_.anInt241
						&& i_513_ < i_517_ + iComponent_518_.anInt238) {
						aStringArray1184[anInt1183] = iComponent_518_.aString268;
						anIntArray981[anInt1183] = 890;
						anIntArray980[anInt1183] = iComponent_518_.anInt215;
						anInt1183++;
					}
					if (iComponent_518_.anInt289 == 5 && i_511_ >= i_516_ && i_513_ >= i_517_
						&& i_511_ < i_516_ + iComponent_518_.anInt241
						&& i_513_ < i_517_ + iComponent_518_.anInt238) {
						aStringArray1184[anInt1183] = iComponent_518_.aString268;
						anIntArray981[anInt1183] = 518;
						anIntArray980[anInt1183] = iComponent_518_.anInt215;
						anInt1183++;
					}
					if (iComponent_518_.anInt289 == 6 && aBoolean1239 == false && i_511_ >= i_516_
						&& i_513_ >= i_517_ && i_511_ < i_516_ + iComponent_518_.anInt241
						&& i_513_ < i_517_ + iComponent_518_.anInt238) {
						aStringArray1184[anInt1183] = iComponent_518_.aString268;
						anIntArray981[anInt1183] = 575;
						anIntArray980[anInt1183] = iComponent_518_.anInt215;
						anInt1183++;
					}
					if (iComponent_518_.anInt236 == 2) {
						int i_519_ = 0;
						for (int i_520_ = 0; i_520_ < iComponent_518_.anInt238; i_520_++) {
							for (int i_521_ = 0; i_521_ < iComponent_518_.anInt241; i_521_++) {
								int i_522_ = i_516_ + i_521_ * (iComponent_518_.anInt263 + 32);
								int i_523_ = i_517_ + i_520_ * (iComponent_518_.anInt244 + 32);
								if (i_519_ < 20) {
									i_522_ += iComponent_518_.anIntArray221[i_519_];
									i_523_ += iComponent_518_.anIntArray213[i_519_];
								}
								if (i_511_ >= i_522_ && i_513_ >= i_523_ && i_511_ < i_522_ + 32
									&& i_513_ < i_523_ + 32) {
									anInt1063 = i_519_;
									anInt1064 = iComponent_518_.anInt215;
									if (iComponent_518_.anIntArray269[i_519_] > 0) {
										ItemDefinition itemDefinition = ItemDefinition
											.method212((iComponent_518_.anIntArray269[i_519_]) - 1);
										if (anInt1146 == 1 && iComponent_518_.aBoolean229) {
											if ((iComponent_518_.anInt215 != anInt1148)
												|| i_519_ != anInt1147) {
												aStringArray1184[anInt1183] = ("Use "
													+ (((Client) this).aString1150) + " with @lre@" + itemDefinition.examine);
												anIntArray981[anInt1183] = 903;
												anIntArray982[anInt1183] = itemDefinition.anInt363;
												anIntArray979[anInt1183] = i_519_;
												anIntArray980[anInt1183] = iComponent_518_.anInt215;
												anInt1183++;
											}
										} else if (anInt1171 == 1 && (iComponent_518_.aBoolean229)) {
											if ((anInt1173 & 0x10) == 16) {
												aStringArray1184[anInt1183] = ((((Client) this).aString1174)
													+ " @lre@" + itemDefinition.examine);
												anIntArray981[anInt1183] = 361;
												anIntArray982[anInt1183] = itemDefinition.anInt363;
												anIntArray979[anInt1183] = i_519_;
												anIntArray980[anInt1183] = iComponent_518_.anInt215;
												anInt1183++;
											}
										} else {
											if (iComponent_518_.aBoolean229) {
												for (int i_524_ = 4; i_524_ >= 3; i_524_--) {
													if (((itemDefinition.actions) != null)
														&& ((itemDefinition.actions[i_524_]) != null)) {
														aStringArray1184[anInt1183] = ((itemDefinition.actions[i_524_])
															+ " @lre@" + (itemDefinition.examine));
														if (i_524_ == 3) {
															anIntArray981[anInt1183] = 227;
														}
														if (i_524_ == 4) {
															anIntArray981[anInt1183] = 891;
														}
														anIntArray982[anInt1183] = itemDefinition.anInt363;
														anIntArray979[anInt1183] = i_519_;
														anIntArray980[anInt1183] = (iComponent_518_.anInt215);
														anInt1183++;
													} else if (i_524_ == 4) {
														aStringArray1184[anInt1183] = ("Drop @lre@" + (itemDefinition.examine));
														anIntArray981[anInt1183] = 891;
														anIntArray982[anInt1183] = itemDefinition.anInt363;
														anIntArray979[anInt1183] = i_519_;
														anIntArray980[anInt1183] = (iComponent_518_.anInt215);
														anInt1183++;
													}
												}
											}
											if (iComponent_518_.aBoolean288) {
												aStringArray1184[anInt1183] = ("Use @lre@" + itemDefinition.examine);
												anIntArray981[anInt1183] = 52;
												anIntArray982[anInt1183] = itemDefinition.anInt363;
												anIntArray979[anInt1183] = i_519_;
												anIntArray980[anInt1183] = iComponent_518_.anInt215;
												anInt1183++;
											}
											if (iComponent_518_.aBoolean229
												&& (itemDefinition.actions != null)) {
												for (int i_525_ = 2; i_525_ >= 0; i_525_--) {
													if ((itemDefinition.actions[i_525_]) != null) {
														aStringArray1184[anInt1183] = ((itemDefinition.actions[i_525_])
															+ " @lre@" + (itemDefinition.examine));
														if (i_525_ == 0) {
															anIntArray981[anInt1183] = 961;
														}
														if (i_525_ == 1) {
															anIntArray981[anInt1183] = 399;
														}
														if (i_525_ == 2) {
															anIntArray981[anInt1183] = 324;
														}
														anIntArray982[anInt1183] = itemDefinition.anInt363;
														anIntArray979[anInt1183] = i_519_;
														anIntArray980[anInt1183] = (iComponent_518_.anInt215);
														anInt1183++;
													}
												}
											}
											if (iComponent_518_.aStringArray262 != null) {
												for (int i_526_ = 4; i_526_ >= 0; i_526_--) {
													if ((iComponent_518_.aStringArray262[i_526_]) != null) {
														aStringArray1184[anInt1183] = ((iComponent_518_.aStringArray262[i_526_])
															+ " @lre@" + (itemDefinition.examine));
														if (i_526_ == 0) {
															anIntArray981[anInt1183] = 9;
														}
														if (i_526_ == 1) {
															anIntArray981[anInt1183] = 225;
														}
														if (i_526_ == 2) {
															anIntArray981[anInt1183] = 444;
														}
														if (i_526_ == 3) {
															anIntArray981[anInt1183] = 564;
														}
														if (i_526_ == 4) {
															anIntArray981[anInt1183] = 894;
														}
														anIntArray982[anInt1183] = itemDefinition.anInt363;
														anIntArray979[anInt1183] = i_519_;
														anIntArray980[anInt1183] = (iComponent_518_.anInt215);
														anInt1183++;
													}
												}
											}
											aStringArray1184[anInt1183] = ("Examine @lre@" + itemDefinition.examine);
											anIntArray981[anInt1183] = 1094;
											anIntArray982[anInt1183] = itemDefinition.anInt363;
											anIntArray979[anInt1183] = i_519_;
											anIntArray980[anInt1183] = iComponent_518_.anInt215;
											anInt1183++;
										}
									}
								}
								i_519_++;
							}
						}
					}
				}
			}
		}
	}

	public final void method67(int i) {
		for (int i_527_ = 0; i_527_ < npcCount; i_527_++) {
			int i_528_ = ((Client) this).anIntArray1134[i_527_];
			Npc npc = totalNpcs[i_528_];
			if (npc != null) {
				method68(((Npc) npc).npc.aByte642, (byte) -97, npc);
			}
		}
		if (i != -37214) {
			aPacket_964.putByte(41);
		}
	}

	public final void method68(int i, byte i_529_, ObjectInstance objectInstance) {
		if (((ObjectInstance) objectInstance).anInt1610 < 128
			|| (((ObjectInstance) objectInstance).anInt1611 < 128)
			|| (((ObjectInstance) objectInstance).anInt1610 >= 13184)
			|| (((ObjectInstance) objectInstance).anInt1611 >= 13184)) {
			((ObjectInstance) objectInstance).anInt1624 = -1;
			((ObjectInstance) objectInstance).anInt1614 = -1;
			((ObjectInstance) objectInstance).anInt1606 = 0;
			((ObjectInstance) objectInstance).anInt1607 = 0;
			((ObjectInstance) objectInstance).anInt1610 = ((((ObjectInstance) objectInstance).anIntArray1586[0]) * 128 + (((ObjectInstance) objectInstance).anInt1601) * 64);
			((ObjectInstance) objectInstance).anInt1611 = ((((ObjectInstance) objectInstance).anIntArray1587[0]) * 128 + (((ObjectInstance) objectInstance).anInt1601) * 64);
			objectInstance.method575(-56);
		}
		if (objectInstance == Client.myPlayer
			&& ((((ObjectInstance) objectInstance).anInt1610 < 1536)
				|| (((ObjectInstance) objectInstance).anInt1611 < 1536)
				|| (((ObjectInstance) objectInstance).anInt1610 >= 11776) || (((ObjectInstance) objectInstance).anInt1611 >= 11776))) {
			((ObjectInstance) objectInstance).anInt1624 = -1;
			((ObjectInstance) objectInstance).anInt1614 = -1;
			((ObjectInstance) objectInstance).anInt1606 = 0;
			((ObjectInstance) objectInstance).anInt1607 = 0;
			((ObjectInstance) objectInstance).anInt1610 = ((((ObjectInstance) objectInstance).anIntArray1586[0]) * 128 + (((ObjectInstance) objectInstance).anInt1601) * 64);
			((ObjectInstance) objectInstance).anInt1611 = ((((ObjectInstance) objectInstance).anIntArray1587[0]) * 128 + (((ObjectInstance) objectInstance).anInt1601) * 64);
			objectInstance.method575(-56);
		}
		if (((ObjectInstance) objectInstance).anInt1606 > Client.anInt1325) {
			method69(objectInstance, true);
		} else if (((ObjectInstance) objectInstance).anInt1607 >= Client.anInt1325) {
			method70(objectInstance, -31135);
		} else {
			method71(objectInstance, 0);
		}
		method72((byte) 8, objectInstance);
		method73(objectInstance, -136);
		if (i_529_ != -97) {
			/* empty */
		}
	}

	public final void method69(ObjectInstance objectInstance, boolean bool) {
		if (!bool) {
			Client.aBoolean963 = !Client.aBoolean963;
		}
		int i = (((ObjectInstance) objectInstance).anInt1606 - Client.anInt1325);
		int i_530_ = ((((ObjectInstance) objectInstance).anInt1602 * 128) + (((ObjectInstance) objectInstance).anInt1601 * 64));
		int i_531_ = ((((ObjectInstance) objectInstance).anInt1604 * 128) + (((ObjectInstance) objectInstance).anInt1601 * 64));
		((ObjectInstance) objectInstance).anInt1610 += ((i_530_ - ((ObjectInstance) objectInstance).anInt1610) / i);
		((ObjectInstance) objectInstance).anInt1611 += ((i_531_ - ((ObjectInstance) objectInstance).anInt1611) / i);
		((ObjectInstance) objectInstance).anInt1623 = 0;
		if (((ObjectInstance) objectInstance).anInt1608 == 0) {
			((ObjectInstance) objectInstance).anInt1584 = 1024;
		}
		if (((ObjectInstance) objectInstance).anInt1608 == 1) {
			((ObjectInstance) objectInstance).anInt1584 = 1536;
		}
		if (((ObjectInstance) objectInstance).anInt1608 == 2) {
			((ObjectInstance) objectInstance).anInt1584 = 0;
		}
		if (((ObjectInstance) objectInstance).anInt1608 == 3) {
			((ObjectInstance) objectInstance).anInt1584 = 512;
		}
	}

	public final void method70(ObjectInstance objectInstance, int i) {
		if ((((ObjectInstance) objectInstance).anInt1607 == Client.anInt1325)
			|| (((ObjectInstance) objectInstance).anInt1624 == -1)
			|| ((ObjectInstance) objectInstance).anInt1627 != 0
			|| (((ObjectInstance) objectInstance).anInt1626 + 1 > (Sequence.sequences[(((ObjectInstance) objectInstance).anInt1624)]
				.method205(0, (((ObjectInstance) objectInstance).anInt1625))))) {
			int i_532_ = (((ObjectInstance) objectInstance).anInt1607 - (((ObjectInstance) objectInstance).anInt1606));
			int i_533_ = (Client.anInt1325 - (((ObjectInstance) objectInstance).anInt1606));
			int i_534_ = ((((ObjectInstance) objectInstance).anInt1602 * 128) + (((ObjectInstance) objectInstance).anInt1601) * 64);
			int i_535_ = ((((ObjectInstance) objectInstance).anInt1604 * 128) + (((ObjectInstance) objectInstance).anInt1601) * 64);
			int i_536_ = ((((ObjectInstance) objectInstance).anInt1603 * 128) + (((ObjectInstance) objectInstance).anInt1601) * 64);
			int i_537_ = ((((ObjectInstance) objectInstance).anInt1605 * 128) + (((ObjectInstance) objectInstance).anInt1601) * 64);
			((ObjectInstance) objectInstance).anInt1610 = (i_534_
				* (i_532_ - i_533_) + i_536_ * i_533_)
				/ i_532_;
			((ObjectInstance) objectInstance).anInt1611 = (i_535_
				* (i_532_ - i_533_) + i_537_ * i_533_)
				/ i_532_;
		}
		((ObjectInstance) objectInstance).anInt1623 = 0;
		if (((ObjectInstance) objectInstance).anInt1608 == 0) {
			((ObjectInstance) objectInstance).anInt1584 = 1024;
		}
		if (((ObjectInstance) objectInstance).anInt1608 == 1) {
			((ObjectInstance) objectInstance).anInt1584 = 1536;
		}
		if (((ObjectInstance) objectInstance).anInt1608 == 2) {
			((ObjectInstance) objectInstance).anInt1584 = 0;
		}
		if (((ObjectInstance) objectInstance).anInt1608 == 3) {
			((ObjectInstance) objectInstance).anInt1584 = 512;
		}
		((ObjectInstance) objectInstance).anInt1612 = ((ObjectInstance) objectInstance).anInt1584;
		if (i != -31135) {
			/* empty */
		}
	}

	public final void method71(ObjectInstance objectInstance, int i) {
		((ObjectInstance) objectInstance).anInt1588 = ((ObjectInstance) objectInstance).anInt1634;
		if (((ObjectInstance) objectInstance).anInt1633 == 0) {
			((ObjectInstance) objectInstance).anInt1623 = 0;
		} else {
			if ((((ObjectInstance) objectInstance).anInt1624 != -1)
				&& (((ObjectInstance) objectInstance).anInt1627 == 0)) {
				Sequence sequence = (Sequence.sequences[(((ObjectInstance) objectInstance).anInt1624)]);
				if ((((ObjectInstance) objectInstance).anInt1613) > 0
					&& sequence.anInt305 == 0) {
					((ObjectInstance) objectInstance).anInt1623++;
					return;
				}
				if ((((ObjectInstance) objectInstance).anInt1613) <= 0
					&& sequence.anInt306 == 0) {
					((ObjectInstance) objectInstance).anInt1623++;
					return;
				}
			}
			int i_538_ = ((ObjectInstance) objectInstance).anInt1610;
			int i_539_ = ((ObjectInstance) objectInstance).anInt1611;
			int i_540_ = ((((ObjectInstance) objectInstance).anIntArray1586[(((ObjectInstance) objectInstance).anInt1633) - 1]) * 128 + (((ObjectInstance) objectInstance).anInt1601) * 64);
			int i_541_ = ((((ObjectInstance) objectInstance).anIntArray1587[(((ObjectInstance) objectInstance).anInt1633) - 1]) * 128 + (((ObjectInstance) objectInstance).anInt1601) * 64);
			if (i_540_ - i_538_ > 256 || i_540_ - i_538_ < -256 || i_541_ - i_539_ > 256
				|| i_541_ - i_539_ < -256) {
				((ObjectInstance) objectInstance).anInt1610 = i_540_;
				((ObjectInstance) objectInstance).anInt1611 = i_541_;
			} else {
				if (i_538_ < i_540_) {
					if (i_539_ < i_541_) {
						((ObjectInstance) objectInstance).anInt1584 = 1280;
					} else if (i_539_ > i_541_) {
						((ObjectInstance) objectInstance).anInt1584 = 1792;
					} else {
						((ObjectInstance) objectInstance).anInt1584 = 1536;
					}
				} else if (i_538_ > i_540_) {
					if (i_539_ < i_541_) {
						((ObjectInstance) objectInstance).anInt1584 = 768;
					} else if (i_539_ > i_541_) {
						((ObjectInstance) objectInstance).anInt1584 = 256;
					} else {
						((ObjectInstance) objectInstance).anInt1584 = 512;
					}
				} else if (i_539_ < i_541_) {
					((ObjectInstance) objectInstance).anInt1584 = 1024;
				} else {
					((ObjectInstance) objectInstance).anInt1584 = 0;
				}
				int i_542_ = (((((ObjectInstance) objectInstance).anInt1584) - (((ObjectInstance) objectInstance).anInt1612)) & 0x7ff);
				if (i_542_ > 1024) {
					i_542_ -= 2048;
				}
				int i_543_ = (((ObjectInstance) objectInstance).anInt1620);
				if (i != 0) {
					aPacket_964.putByte(34);
				}
				if (i_542_ >= -256 && i_542_ <= 256) {
					i_543_ = (((ObjectInstance) objectInstance).anInt1619);
				} else if (i_542_ >= 256 && i_542_ < 768) {
					i_543_ = (((ObjectInstance) objectInstance).anInt1622);
				} else if (i_542_ >= -768 && i_542_ <= -256) {
					i_543_ = (((ObjectInstance) objectInstance).anInt1621);
				}
				if (i_543_ == -1) {
					i_543_ = (((ObjectInstance) objectInstance).anInt1619);
				}
				((ObjectInstance) objectInstance).anInt1588 = i_543_;
				int i_544_ = 4;
				if (((((ObjectInstance) objectInstance).anInt1612) != (((ObjectInstance) objectInstance).anInt1584))
					&& (((ObjectInstance) objectInstance).anInt1609) == -1
					&& (((ObjectInstance) objectInstance).anInt1600) != 0) {
					i_544_ = 2;
				}
				if (((ObjectInstance) objectInstance).anInt1633 > 2) {
					i_544_ = 6;
				}
				if (((ObjectInstance) objectInstance).anInt1633 > 3) {
					i_544_ = 8;
				}
				if ((((ObjectInstance) objectInstance).anInt1623) > 0
					&& (((ObjectInstance) objectInstance).anInt1633) > 1) {
					i_544_ = 8;
					((ObjectInstance) objectInstance).anInt1623--;
				}
				if (((ObjectInstance) objectInstance).aBooleanArray1591[(((ObjectInstance) objectInstance).anInt1633) - 1]) {
					i_544_ <<= 1;
				}
				if (i_544_ >= 8
					&& ((((ObjectInstance) objectInstance).anInt1588) == (((ObjectInstance) objectInstance).anInt1619))
					&& (((ObjectInstance) objectInstance).anInt1629) != -1) {
					((ObjectInstance) objectInstance).anInt1588 = (((ObjectInstance) objectInstance).anInt1629);
				}
				if (i_538_ < i_540_) {
					((ObjectInstance) objectInstance).anInt1610 += i_544_;
					if ((((ObjectInstance) objectInstance).anInt1610) > i_540_) {
						((ObjectInstance) objectInstance).anInt1610 = i_540_;
					}
				} else if (i_538_ > i_540_) {
					((ObjectInstance) objectInstance).anInt1610 -= i_544_;
					if ((((ObjectInstance) objectInstance).anInt1610) < i_540_) {
						((ObjectInstance) objectInstance).anInt1610 = i_540_;
					}
				}
				if (i_539_ < i_541_) {
					((ObjectInstance) objectInstance).anInt1611 += i_544_;
					if ((((ObjectInstance) objectInstance).anInt1611) > i_541_) {
						((ObjectInstance) objectInstance).anInt1611 = i_541_;
					}
				} else if (i_539_ > i_541_) {
					((ObjectInstance) objectInstance).anInt1611 -= i_544_;
					if ((((ObjectInstance) objectInstance).anInt1611) < i_541_) {
						((ObjectInstance) objectInstance).anInt1611 = i_541_;
					}
				}
				if ((((ObjectInstance) objectInstance).anInt1610) == i_540_
					&& (((ObjectInstance) objectInstance).anInt1611) == i_541_) {
					((ObjectInstance) objectInstance).anInt1633--;
					if ((((ObjectInstance) objectInstance).anInt1613) > 0) {
						((ObjectInstance) objectInstance).anInt1613--;
					}
				}
			}
		}
	}

	public final void method72(byte i, ObjectInstance objectInstance) {
		if (i != 8) {
			anInt928 = cryption.getNextKey();
		}
		if (((ObjectInstance) objectInstance).anInt1600 != 0) {
			if ((((ObjectInstance) objectInstance).anInt1609 != -1)
				&& (((ObjectInstance) objectInstance).anInt1609 < 32768)) {
				Npc npc = (totalNpcs[(((ObjectInstance) objectInstance).anInt1609)]);
				if (npc != null) {
					int i_545_ = ((((ObjectInstance) objectInstance).anInt1610) - ((ObjectInstance) npc).anInt1610);
					int i_546_ = ((((ObjectInstance) objectInstance).anInt1611) - ((ObjectInstance) npc).anInt1611);
					if (i_545_ != 0 || i_546_ != 0) {
						((ObjectInstance) objectInstance).anInt1584 = (int) (Math
							.atan2((double) i_545_, (double) i_546_) * 325.949) & 0x7ff;
					}
				}
			}
			if (((ObjectInstance) objectInstance).anInt1609 >= 32768) {
				int i_547_ = (((ObjectInstance) objectInstance).anInt1609) - 32768;
				if (i_547_ == anInt961) {
					i_547_ = anInt969;
				}
				Player player = totalPlayers[i_547_];
				if (player != null) {
					int i_548_ = ((((ObjectInstance) objectInstance).anInt1610) - ((ObjectInstance) player).anInt1610);
					int i_549_ = ((((ObjectInstance) objectInstance).anInt1611) - ((ObjectInstance) player).anInt1611);
					if (i_548_ != 0 || i_549_ != 0) {
						((ObjectInstance) objectInstance).anInt1584 = (int) (Math
							.atan2((double) i_548_, (double) i_549_) * 325.949) & 0x7ff;
					}
				}
			}
			if (((((ObjectInstance) objectInstance).anInt1598 != 0) || (((ObjectInstance) objectInstance).anInt1599) != 0)
				&& ((((ObjectInstance) objectInstance).anInt1633) == 0 || (((ObjectInstance) objectInstance).anInt1623) > 0)) {
				int i_550_ = ((((ObjectInstance) objectInstance).anInt1610) - ((((ObjectInstance) objectInstance).anInt1598)
					- anInt1040 - anInt1040) * 64);
				int i_551_ = ((((ObjectInstance) objectInstance).anInt1611) - ((((ObjectInstance) objectInstance).anInt1599)
					- anInt1041 - anInt1041) * 64);
				if (i_550_ != 0 || i_551_ != 0) {
					((ObjectInstance) objectInstance).anInt1584 = (int) (Math
						.atan2((double) i_550_, (double) i_551_) * 325.949) & 0x7ff;
				}
				((ObjectInstance) objectInstance).anInt1598 = 0;
				((ObjectInstance) objectInstance).anInt1599 = 0;
			}
			int i_552_ = ((((ObjectInstance) objectInstance).anInt1584 - (((ObjectInstance) objectInstance).anInt1612)) & 0x7ff);
			if (i_552_ != 0) {
				if (i_552_ < (((ObjectInstance) objectInstance).anInt1600)
					|| 2048 - ((ObjectInstance) objectInstance).anInt1600 < i_552_) {
					((ObjectInstance) objectInstance).anInt1612 = (((ObjectInstance) objectInstance).anInt1584);
				} else if (i_552_ > 1024) {
					((ObjectInstance) objectInstance).anInt1612 -= (((ObjectInstance) objectInstance).anInt1600);
				} else {
					((ObjectInstance) objectInstance).anInt1612 += (((ObjectInstance) objectInstance).anInt1600);
				}
				((ObjectInstance) objectInstance).anInt1612 &= 0x7ff;
				if (((((ObjectInstance) objectInstance).anInt1588) == (((ObjectInstance) objectInstance).anInt1634))
					&& ((((ObjectInstance) objectInstance).anInt1612) != (((ObjectInstance) objectInstance).anInt1584))) {
					if ((((ObjectInstance) objectInstance).anInt1635) != -1) {
						((ObjectInstance) objectInstance).anInt1588 = ((ObjectInstance) objectInstance).anInt1635;
					} else {
						((ObjectInstance) objectInstance).anInt1588 = ((ObjectInstance) objectInstance).anInt1619;
					}
				}
			}
		}
	}

	public final void method73(ObjectInstance objectInstance, int i) {
		while (i >= 0) {
			anInt1328 = cryption.getNextKey();
		}
		((ObjectInstance) objectInstance).aBoolean1592 = false;
		if (((ObjectInstance) objectInstance).anInt1588 != -1) {
			Sequence sequence = (Sequence.sequences[(((ObjectInstance) objectInstance).anInt1588)]);
			((ObjectInstance) objectInstance).anInt1590++;
			if ((((ObjectInstance) objectInstance).anInt1589 < sequence.anInt294)
				&& (((ObjectInstance) objectInstance).anInt1590 > sequence
					.method205(0, ((ObjectInstance) objectInstance).anInt1589))) {
				((ObjectInstance) objectInstance).anInt1590 = 1;
				((ObjectInstance) objectInstance).anInt1589++;
			}
			if (((ObjectInstance) objectInstance).anInt1589 >= sequence.anInt294) {
				((ObjectInstance) objectInstance).anInt1590 = 1;
				((ObjectInstance) objectInstance).anInt1589 = 0;
			}
		}
		if (((ObjectInstance) objectInstance).anInt1614 != -1
			&& Client.anInt1325 >= (((ObjectInstance) objectInstance).anInt1617)) {
			if (((ObjectInstance) objectInstance).anInt1615 < 0) {
				((ObjectInstance) objectInstance).anInt1615 = 0;
			}
			Sequence sequence = (SpotAnimation.spotAnims[(((ObjectInstance) objectInstance).anInt1614)].sequence);
			((ObjectInstance) objectInstance).anInt1616++;
			if ((((ObjectInstance) objectInstance).anInt1615 < sequence.anInt294)
				&& (((ObjectInstance) objectInstance).anInt1616 > sequence
					.method205(0, ((ObjectInstance) objectInstance).anInt1615))) {
				((ObjectInstance) objectInstance).anInt1616 = 1;
				((ObjectInstance) objectInstance).anInt1615++;
			}
			if ((((ObjectInstance) objectInstance).anInt1615 >= sequence.anInt294)
				&& ((((ObjectInstance) objectInstance).anInt1615) < 0 || (((ObjectInstance) objectInstance).anInt1615) >= sequence.anInt294)) {
				((ObjectInstance) objectInstance).anInt1614 = -1;
			}
		}
		if (((ObjectInstance) objectInstance).anInt1624 != -1
			&& (((ObjectInstance) objectInstance).anInt1627 <= 1)) {
			Sequence sequence = (Sequence.sequences[(((ObjectInstance) objectInstance).anInt1624)]);
			if (sequence.anInt305 == 1
				&& (((ObjectInstance) objectInstance).anInt1613 > 0)
				&& (((ObjectInstance) objectInstance).anInt1606 <= Client.anInt1325)
				&& (((ObjectInstance) objectInstance).anInt1607 < Client.anInt1325)) {
				((ObjectInstance) objectInstance).anInt1627 = 1;
				return;
			}
		}
		if (((ObjectInstance) objectInstance).anInt1624 != -1
			&& (((ObjectInstance) objectInstance).anInt1627 == 0)) {
			Sequence sequence = (Sequence.sequences[(((ObjectInstance) objectInstance).anInt1624)]);
			((ObjectInstance) objectInstance).anInt1626++;
			if ((((ObjectInstance) objectInstance).anInt1625 < sequence.anInt294)
				&& (((ObjectInstance) objectInstance).anInt1626 > sequence
					.method205(0, ((ObjectInstance) objectInstance).anInt1625))) {
				((ObjectInstance) objectInstance).anInt1626 = 1;
				((ObjectInstance) objectInstance).anInt1625++;
			}
			if (((ObjectInstance) objectInstance).anInt1625 >= sequence.anInt294) {
				((ObjectInstance) objectInstance).anInt1625 -= sequence.anInt298;
				((ObjectInstance) objectInstance).anInt1628++;
				if (((ObjectInstance) objectInstance).anInt1628 >= sequence.anInt304) {
					((ObjectInstance) objectInstance).anInt1624 = -1;
				}
				if ((((ObjectInstance) objectInstance).anInt1625) < 0
					|| (((ObjectInstance) objectInstance).anInt1625) >= sequence.anInt294) {
					((ObjectInstance) objectInstance).anInt1624 = -1;
				}
			}
			((ObjectInstance) objectInstance).aBoolean1592 = sequence.aBoolean300;
		}
		if (((ObjectInstance) objectInstance).anInt1627 > 0) {
			((ObjectInstance) objectInstance).anInt1627--;
		}
	}

	public final void method74(int i) {
		if (anInt1053 != -1 && (anInt1071 == 2 || aGraphicsBuffer_15 != null)) {
			if (anInt1071 == 2) {
				method88(anInt951, anInt1053, (byte) 5);
				if (anInt960 != -1) {
					method88(anInt951, anInt960, (byte) 5);
				}
				anInt951 = 0;
				method147(anInt1140);
				aGraphicsBuffer_15.method230(false);
				Renderer3D.anIntArray1538 = anIntArray1003;
				Renderer2D.method458(4);
				aBoolean1046 = true;
				Interface iComponent = Interface.method195(anInt1053);
				if (iComponent.anInt241 == 512 && iComponent.anInt238 == 334
					&& iComponent.anInt236 == 0) {
					iComponent.anInt241 = 765;
					iComponent.anInt238 = 503;
				}
				method142(0, 0, iComponent, 0, 8);
				if (anInt960 != -1) {
					iComponent = Interface.method195(anInt960);
					if (iComponent.anInt241 == 512 && iComponent.anInt238 == 334
						&& iComponent.anInt236 == 0) {
						iComponent.anInt241 = 765;
						iComponent.anInt238 = 503;
					}
					method142(0, 0, iComponent, 0, 8);
				}
				if (!aBoolean1065) {
					method91(-521);
					method34((byte) -79);
				} else {
					method128(false);
				}
			}
			aGraphicsBuffer_15.method231(0, 0, aGraphics14, aBoolean1074);
		} else {
			if (aBoolean1046) {
				method122(-906);
				aBoolean1046 = false;
				aGraphicsBuffer_906.method231(4, 0, aGraphics14, aBoolean1074);
				aGraphicsBuffer_907.method231(357, 0, aGraphics14, aBoolean1074);
				aGraphicsBuffer_908.method231(4, 722, aGraphics14, aBoolean1074);
				aGraphicsBuffer_909.method231(205, 743, aGraphics14, aBoolean1074);
				aGraphicsBuffer_910.method231(0, 0, aGraphics14, aBoolean1074);
				aGraphicsBuffer_911.method231(4, 516, aGraphics14, aBoolean1074);
				aGraphicsBuffer_912.method231(205, 516, aGraphics14, aBoolean1074);
				aGraphicsBuffer_913.method231(357, 496, aGraphics14, aBoolean1074);
				aGraphicsBuffer_914.method231(338, 0, aGraphics14, aBoolean1074);
				drawInventoryRequest = true;
				aBoolean1240 = true;
				aBoolean950 = true;
				aBoolean1212 = true;
				if (anInt1071 != 2) {
					aGraphicsBuffer_1158.method231(4, 4, aGraphics14, aBoolean1074);
					aGraphicsBuffer_1157.method231(4, 550, aGraphics14, aBoolean1074);
				}
				Client.anInt1237++;
				if (Client.anInt1237 > 85) {
					Client.anInt1237 = 0;
					aPacket_964.putOpcode(168);
				}
			}
			if (anInt1071 == 2) {
				method151(2);
			}
			if (aBoolean1065 && anInt1304 == 1) {
				drawInventoryRequest = true;
			}
			if (anInt1089 != -1) {
				boolean bool = method88(anInt951, anInt1089, (byte) 5);
				if (bool) {
					drawInventoryRequest = true;
				}
			}
			if (anInt1332 == 2) {
				drawInventoryRequest = true;
			}
			if (anInt1113 == 2) {
				drawInventoryRequest = true;
			}
			if (drawInventoryRequest) {
				method134((byte) 7);
				drawInventoryRequest = false;
			}
			if (anInt988 == -1 && anInt1244 == 0) {
				anIComponent_1249.anInt231 = anInt1107 - anInt851 - 77;
				if (anInt22 > 448 && anInt22 < 560 && anInt23 > 332) {
					method42(anInt1107, 0, anIComponent_1249, (byte) 102, anInt23 - 357, -1,
						anInt22 - 17, 77, 463);
				}
				int i_553_ = anInt1107 - 77 - anIComponent_1249.anInt231;
				if (i_553_ < 0) {
					i_553_ = 0;
				}
				if (i_553_ > anInt1107 - 77) {
					i_553_ = anInt1107 - 77;
				}
				if (anInt851 != i_553_) {
					anInt851 = i_553_;
					aBoolean1240 = true;
				}
			}
			if (anInt988 == -1 && anInt1244 == 3) {
				int i_554_ = anInt862 * 14 + 7;
				anIComponent_1249.anInt231 = anInt865;
				if (anInt22 > 448 && anInt22 < 560 && anInt23 > 332) {
					method42(i_554_, 0, anIComponent_1249, (byte) 102, anInt23 - 357, -1,
						anInt22 - 17, 77, 463);
				}
				int i_555_ = anIComponent_1249.anInt231;
				if (i_555_ < 0) {
					i_555_ = 0;
				}
				if (i_555_ > i_554_ - 77) {
					i_555_ = i_554_ - 77;
				}
				if (anInt865 != i_555_) {
					anInt865 = i_555_;
					aBoolean1240 = true;
				}
			}
			if (anInt988 != -1) {
				boolean bool = method88(anInt951, anInt988, (byte) 5);
				if (bool) {
					aBoolean1240 = true;
				}
			}
			if (anInt1332 == 3) {
				aBoolean1240 = true;
			}
			if (anInt1113 == 3) {
				aBoolean1240 = true;
			}
			if (aString1058 != null) {
				aBoolean1240 = true;
			}
			if (aBoolean1065 && anInt1304 == 2) {
				aBoolean1240 = true;
			}
			if (aBoolean1240) {
				method84(0);
				aBoolean1240 = false;
			}
			if (anInt1071 == 2) {
				method87(503);
				aGraphicsBuffer_1157.method231(4, 550, aGraphics14, aBoolean1074);
			}
			if (anInt1213 != -1) {
				aBoolean950 = true;
			}
			if (aBoolean950) {
				if (anInt1213 != -1 && anInt1213 == anInt1285) {
					anInt1213 = -1;
					aPacket_964.putOpcode(119);
					aPacket_964.putByte(anInt1285);
				}
				aBoolean950 = false;
				aGraphicsBuffer_1110.method230(false);
				backhmid1.method501(0, 0);
				if (anInt1089 == -1) {
					if (anIntArray1081[anInt1285] != -1) {
						if (anInt1285 == 0) {
							aIndexedSprite_880.method501(10, 22);
						}
						if (anInt1285 == 1) {
							aIndexedSprite_881.method501(8, 54);
						}
						if (anInt1285 == 2) {
							aIndexedSprite_881.method501(8, 82);
						}
						if (anInt1285 == 3) {
							aIndexedSprite_882.method501(8, 110);
						}
						if (anInt1285 == 4) {
							aIndexedSprite_884.method501(8, 153);
						}
						if (anInt1285 == 5) {
							aIndexedSprite_884.method501(8, 181);
						}
						if (anInt1285 == 6) {
							aIndexedSprite_883.method501(9, 209);
						}
					}
					if (anIntArray1081[0] != -1 && (anInt1213 != 0 || Client.anInt1325 % 20 < 10)) {
						sideicons[0].method501(13, 29);
					}
					if (anIntArray1081[1] != -1 && (anInt1213 != 1 || Client.anInt1325 % 20 < 10)) {
						sideicons[1].method501(11, 53);
					}
					if (anIntArray1081[2] != -1 && (anInt1213 != 2 || Client.anInt1325 % 20 < 10)) {
						sideicons[2].method501(11, 82);
					}
					if (anIntArray1081[3] != -1 && (anInt1213 != 3 || Client.anInt1325 % 20 < 10)) {
						sideicons[3].method501(12, 115);
					}
					if (anIntArray1081[4] != -1 && (anInt1213 != 4 || Client.anInt1325 % 20 < 10)) {
						sideicons[4].method501(13, 153);
					}
					if (anIntArray1081[5] != -1 && (anInt1213 != 5 || Client.anInt1325 % 20 < 10)) {
						sideicons[5].method501(11, 180);
					}
					if (anIntArray1081[6] != -1 && (anInt1213 != 6 || Client.anInt1325 % 20 < 10)) {
						sideicons[6].method501(13, 208);
					}
				}
				aGraphicsBuffer_1110.method231(160, 516, aGraphics14, aBoolean1074);
				aGraphicsBuffer_1109.method230(false);
				backbase2.method501(0, 0);
				if (anInt1089 == -1) {
					if (anIntArray1081[anInt1285] != -1) {
						if (anInt1285 == 7) {
							aIndexedSprite_983.method501(0, 42);
						}
						if (anInt1285 == 8) {
							aIndexedSprite_984.method501(0, 74);
						}
						if (anInt1285 == 9) {
							aIndexedSprite_984.method501(0, 102);
						}
						if (anInt1285 == 10) {
							aIndexedSprite_985.method501(1, 130);
						}
						if (anInt1285 == 11) {
							aIndexedSprite_987.method501(0, 173);
						}
						if (anInt1285 == 12) {
							aIndexedSprite_987.method501(0, 201);
						}
						if (anInt1285 == 13) {
							aIndexedSprite_986.method501(0, 229);
						}
					}
					if (anIntArray1081[8] != -1 && (anInt1213 != 8 || Client.anInt1325 % 20 < 10)) {
						sideicons[7].method501(2, 74);
					}
					if (anIntArray1081[9] != -1 && (anInt1213 != 9 || Client.anInt1325 % 20 < 10)) {
						sideicons[8].method501(3, 102);
					}
					if (anIntArray1081[10] != -1 && (anInt1213 != 10 || Client.anInt1325 % 20 < 10)) {
						sideicons[9].method501(4, 137);
					}
					if (anIntArray1081[11] != -1 && (anInt1213 != 11 || Client.anInt1325 % 20 < 10)) {
						sideicons[10].method501(2, 174);
					}
					if (anIntArray1081[12] != -1 && (anInt1213 != 12 || Client.anInt1325 % 20 < 10)) {
						sideicons[11].method501(2, 201);
					}
					if (anIntArray1081[13] != -1 && (anInt1213 != 13 || Client.anInt1325 % 20 < 10)) {
						sideicons[12].method501(2, 226);
					}
				}
				aGraphicsBuffer_1109.method231(466, 496, aGraphics14, aBoolean1074);
				aGraphicsBuffer_1158.method230(false);
				Renderer3D.anIntArray1538 = anIntArray1002;
			}
			if (aBoolean1212) {
				aBoolean1212 = false;
				aGraphicsBuffer_1108.method230(false);
				backbase1.method501(0, 0);
				aFont_1060.method482(true, 16777215, 28, 55, "Public chat");
				if (anInt1006 == 0) {
					aFont_1060.method482(true, 65280, 41, 55, "On");
				}
				if (anInt1006 == 1) {
					aFont_1060.method482(true, 16776960, 41, 55, "Friends");
				}
				if (anInt1006 == 2) {
					aFont_1060.method482(true, 16711680, 41, 55, "Off");
				}
				if (anInt1006 == 3) {
					aFont_1060.method482(true, 65535, 41, 55, "Hide");
				}
				aFont_1060.method482(true, 16777215, 28, 184, "Private chat");
				if (anInt887 == 0) {
					aFont_1060.method482(true, 65280, 41, 184, "On");
				}
				if (anInt887 == 1) {
					aFont_1060.method482(true, 16776960, 41, 184, "Friends");
				}
				if (anInt887 == 2) {
					aFont_1060.method482(true, 16711680, 41, 184, "Off");
				}
				aFont_1060.method482(true, 16777215, 28, 324, "Trade/compete");
				if (anInt1227 == 0) {
					aFont_1060.method482(true, 65280, 41, 324, "On");
				}
				if (anInt1227 == 1) {
					aFont_1060.method482(true, 16776960, 41, 324, "Friends");
				}
				if (anInt1227 == 2) {
					aFont_1060.method482(true, 16711680, 41, 324, "Off");
				}
				aFont_1060.method482(true, 16777215, 33, 458, "Report abuse");
				aGraphicsBuffer_1108.method231(453, 0, aGraphics14, aBoolean1074);
				aGraphicsBuffer_1158.method230(false);
				Renderer3D.anIntArray1538 = anIntArray1002;
			}
			anInt951 = 0;
			if (i != 7) {
				for (int i_556_ = 1; i_556_ > 0; i_556_++) {
					/* empty */
				}
			}
		}
	}

	public final void method75(int i) {
		packetSize += i;
		if (anInt1223 != 0) {
			Font font = aFont_1060;
			int i_557_ = 0;
			if (anInt1057 != 0) {
				i_557_ = 1;
			}
			for (int i_558_ = 0; i_558_ < 100; i_558_++) {
				if (aStringArray1298[i_558_] != null) {
					int i_559_ = anIntArray1296[i_558_];
					String string = aStringArray1297[i_558_];
					int i_560_ = 0;
					if (string != null && string.startsWith("@cr1@")) {
						string = string.substring(5);
						i_560_ = 1;
					}
					if (string != null && string.startsWith("@cr2@")) {
						string = string.substring(5);
						i_560_ = 2;
					}
					if ((i_559_ == 3 || i_559_ == 7)
						&& (i_559_ == 7 || anInt887 == 0 || anInt887 == 1
							&& method148(13292, string))) {
						int i_561_ = 329 - i_557_ * 13;
						int i_562_ = 4;
						font.method485(2245, i_562_, 0, i_561_, "From");
						font.method485(2245, i_562_, 65535, i_561_ - 1, "From");
						i_562_ += font.method483((byte) 35, "From ");
						if (i_560_ == 1) {
							mod_icons[0].method501(i_561_ - 12, i_562_);
							i_562_ += 14;
						}
						if (i_560_ == 2) {
							mod_icons[1].method501(i_561_ - 12, i_562_);
							i_562_ += 14;
						}
						font.method485(2245, i_562_, 0, i_561_,
							(string + ": " + (aStringArray1298[i_558_])));
						font.method485(2245, i_562_, 65535, i_561_ - 1,
							(string + ": " + (aStringArray1298[i_558_])));
						if (++i_557_ >= 5) {
							break;
						}
					}
					if (i_559_ == 5 && anInt887 < 2) {
						int i_563_ = 329 - i_557_ * 13;
						font.method485(2245, 4, 0, i_563_, (aStringArray1298[i_558_]));
						font.method485(2245, 4, 65535, i_563_ - 1, (aStringArray1298[i_558_]));
						if (++i_557_ >= 5) {
							break;
						}
					}
					if (i_559_ == 6 && anInt887 < 2) {
						int i_564_ = 329 - i_557_ * 13;
						font.method485(2245, 4, 0, i_564_,
							("To " + string + ": " + (aStringArray1298[i_558_])));
						font.method485(2245, 4, 65535, i_564_ - 1,
							("To " + string + ": " + (aStringArray1298[i_558_])));
						if (++i_557_ >= 5) {
							break;
						}
					}
				}
			}
		}
	}

	public final void init() {
		Client.anInt923 = Integer.parseInt(getParameter("nodeid"));
		Client.anInt924 = Integer.parseInt(getParameter("portoff"));
		String string = getParameter("lowmem");
		if (string != null && string.equals("1")) {
			Client.method101(true);
		} else {
			Client.method27(true);
		}
		String string_565_ = getParameter("free");
		if (string_565_ != null && string_565_.equals("1")) {
			Client.aBoolean925 = false;
		} else {
			Client.aBoolean925 = true;
		}
		this.method2(765, 503, 2);
	}

	public final void method76(int i) {
		while (i >= 0) {
			aDequeArrayArrayArray1323 = null;
		}
		for (Class50_Sub1_Sub4_Sub6 class50_sub1_sub4_sub6 = (Class50_Sub1_Sub4_Sub6) aDeque_1210
			.method158(); class50_sub1_sub4_sub6 != null; class50_sub1_sub4_sub6 = (Class50_Sub1_Sub4_Sub6) aDeque_1210
			.method160(1)) {
			if (class50_sub1_sub4_sub6.anInt1731 != anInt1091
				|| class50_sub1_sub4_sub6.aBoolean1736) {
				class50_sub1_sub4_sub6.method453();
			} else if (Client.anInt1325 >= class50_sub1_sub4_sub6.anInt1740) {
				class50_sub1_sub4_sub6.method615((byte) 1, anInt951);
				if (class50_sub1_sub4_sub6.aBoolean1736) {
					class50_sub1_sub4_sub6.method453();
				} else {
					aClass22_1164.method252(-1, class50_sub1_sub4_sub6,
						class50_sub1_sub4_sub6.anInt1732, class50_sub1_sub4_sub6.anInt1734, false,
						0, class50_sub1_sub4_sub6.anInt1731, 60, class50_sub1_sub4_sub6.anInt1733,
						0);
				}
			}
		}
	}

	public final void method77(boolean bool) {
		if (bool) {
			opcode = -1;
		}
		for (;;) {
			Class50_Sub1_Sub3 class50_sub1_sub3 = aClass32_Sub1_1291.method330();
			if (class50_sub1_sub3 == null) {
				break;
			}
			if (((Class50_Sub1_Sub3) class50_sub1_sub3).anInt1467 == 0) {
				Model.method586(((Class50_Sub1_Sub3) class50_sub1_sub3).aByteArray1470,
					((Class50_Sub1_Sub3) class50_sub1_sub3).anInt1468, (byte) 7);
				if ((aClass32_Sub1_1291.method325(
					(((Class50_Sub1_Sub3) class50_sub1_sub3).anInt1468), -493) & 0x62) != 0) {
					drawInventoryRequest = true;
					if (anInt988 != -1 || anInt1191 != -1) {
						aBoolean1240 = true;
					}
				}
			}
			if (((Class50_Sub1_Sub3) class50_sub1_sub3).anInt1467 == 1
				&& (((Class50_Sub1_Sub3) class50_sub1_sub3).aByteArray1470 != null)) {
				Class21.method236((((Class50_Sub1_Sub3) class50_sub1_sub3).aByteArray1470), true);
			}
			if (((Class50_Sub1_Sub3) class50_sub1_sub3).anInt1467 == 2
				&& (((Class50_Sub1_Sub3) class50_sub1_sub3).anInt1468 == anInt1270)
				&& (((Class50_Sub1_Sub3) class50_sub1_sub3).aByteArray1470 != null)) {
				method24(aBoolean1271, (((Class50_Sub1_Sub3) class50_sub1_sub3).aByteArray1470),
					659);
			}
			if (((Class50_Sub1_Sub3) class50_sub1_sub3).anInt1467 == 3 && anInt1071 == 1) {
				for (int i = 0; i < aByteArrayArray838.length; i++) {
					if (anIntArray857[i] == ((Class50_Sub1_Sub3) class50_sub1_sub3).anInt1468) {
						aByteArrayArray838[i] = (((Class50_Sub1_Sub3) class50_sub1_sub3).aByteArray1470);
						if ((((Class50_Sub1_Sub3) class50_sub1_sub3).aByteArray1470) == null) {
							anIntArray857[i] = -1;
						}
						break;
					}
					if (anIntArray858[i] == ((Class50_Sub1_Sub3) class50_sub1_sub3).anInt1468) {
						aByteArrayArray1232[i] = (((Class50_Sub1_Sub3) class50_sub1_sub3).aByteArray1470);
						if ((((Class50_Sub1_Sub3) class50_sub1_sub3).aByteArray1470) == null) {
							anIntArray858[i] = -1;
						}
						break;
					}
				}
			}
			if (((Class50_Sub1_Sub3) class50_sub1_sub3).anInt1467 == 93
				&& aClass32_Sub1_1291.method334(((Class50_Sub1_Sub3) class50_sub1_sub3).anInt1468,
					false)) {
				Class8.method169(aClass32_Sub1_1291, new Packet(
					(((Class50_Sub1_Sub3) class50_sub1_sub3).aByteArray1470)), (byte) -3);
			}
		}
	}

	public final boolean method78(int i) {
		if (i <= 0) {
			for (int i_566_ = 1; i_566_ > 0; i_566_++) {
				/* empty */
			}
		}
		return Signlink.waveplay();
	}

	public final void method79(String string, String string_567_, boolean bool) {
		Signlink.errorname = string;
		try {
			if (!bool) {
				aString957 = "";
				aString958 = "Connecting to server...";
				method131(true);
			}
			socket = new Socket((byte) 2, method32(Client.anInt924 + 43594), this);
			long l = TextUtil.method299(string);
			int i = (int) (l >> 16 & 0x1fL);
			aPacket_964.offset = 0;
			aPacket_964.putByte(14);
			aPacket_964.putByte(i);
			socket.method228(0, 2, 0, aPacket_964.payload);
			for (int i_568_ = 0; i_568_ < 8; i_568_++) {
				socket.method225();
			}
			int i_569_ = socket.method225();
			int i_570_ = i_569_;
			if (i_569_ == 0) {
				socket.method227(inputStream.payload, 0, 8);
				inputStream.offset = 0;
				aLong930 = inputStream.getLong();
				int[] is = new int[4];
				is[0] = (int) (Math.random() * 9.9999999E7);
				is[1] = (int) (Math.random() * 9.9999999E7);
				is[2] = (int) (aLong930 >> 32);
				is[3] = (int) aLong930;
				aPacket_964.offset = 0;
				aPacket_964.putByte(10);
				aPacket_964.putInt(is[0]);
				aPacket_964.putInt(is[1]);
				aPacket_964.putInt(is[2]);
				aPacket_964.putInt(is[3]);
				aPacket_964.putInt(Signlink.uid);
				aPacket_964.putString(string);
				aPacket_964.putString(string_567_);
				aPacket_964.encodeRsa(Client.aBigInteger840, Client.aBigInteger1316);
				aPacket_929.offset = 0;
				if (bool) {
					aPacket_929.putByte(18);
				} else {
					aPacket_929.putByte(16);
				}
				aPacket_929.putByte((aPacket_964.offset) + 36 + 1 + 1 + 2);
				aPacket_929.putByte(255);
				aPacket_929.putShort(377);
				aPacket_929.putByte(Client.aBoolean926 ? 1 : 0);
				for (int i_571_ = 0; i_571_ < 9; i_571_++) {
					aPacket_929.putInt(anIntArray837[i_571_]);
				}
				aPacket_929.putBytes(aPacket_964.payload, aPacket_964.offset, 0);
				aPacket_964.packetCryption = new IsaacCipher(is);
				for (int i_572_ = 0; i_572_ < 4; i_572_++) {
					is[i_572_] += 50;
				}
				cryption = new IsaacCipher(is);
				socket.method228(0, aPacket_929.offset, 0, aPacket_929.payload);
				i_569_ = socket.method225();
			}
			if (i_569_ == 1) {
				try {
					Thread.sleep(2000L);
				} catch (Exception exception) {
					/* empty */
				}
				method79(string, string_567_, bool);
			} else if (i_569_ == 2) {
				anInt867 = socket.method225();
				Client.aBoolean962 = socket.method225() == 1;
				((Client) this).aLong902 = 0L;
				((Client) this).anInt1299 = 0;
				((Client) this).aClass7_1248.anInt136 = 0;
				aBoolean19 = true;
				((Client) this).aBoolean1275 = true;
				aBoolean1137 = true;
				aPacket_964.offset = 0;
				inputStream.offset = 0;
				opcode = -1;
				anInt903 = -1;
				anInt904 = -1;
				anInt905 = -1;
				packetSize = 0;
				anInt871 = 0;
				anInt1057 = 0;
				anInt873 = 0;
				anInt1197 = 0;
				anInt1183 = 0;
				aBoolean1065 = false;
				anInt20 = 0;
				for (int i_573_ = 0; i_573_ < 100; i_573_++) {
					aStringArray1298[i_573_] = null;
				}
				anInt1146 = 0;
				anInt1171 = 0;
				anInt1071 = 0;
				anInt1035 = 0;
				anInt853 = (int) (Math.random() * 100.0) - 50;
				anInt1009 = (int) (Math.random() * 110.0) - 55;
				anInt1255 = (int) (Math.random() * 80.0) - 40;
				anInt916 = (int) (Math.random() * 120.0) - 60;
				anInt1233 = (int) (Math.random() * 30.0) - 20;
				anInt1252 = (int) (Math.random() * 20.0) - 10 & 0x7ff;
				anInt1050 = 0;
				anInt1276 = -1;
				anInt1120 = 0;
				anInt1121 = 0;
				playerCount = 0;
				npcCount = 0;
				for (int i_574_ = 0; i_574_ < anInt968; i_574_++) {
					totalPlayers[i_574_] = null;
					aPacketArray975[i_574_] = null;
				}
				for (int i_575_ = 0; i_575_ < 16384; i_575_++) {
					totalNpcs[i_575_] = null;
				}
				Client.myPlayer = totalPlayers[anInt969] = new Player();
				aDeque_1282.method162();
				aDeque_1210.method162();
				for (int i_576_ = 0; i_576_ < 4; i_576_++) {
					for (int i_577_ = 0; i_577_ < 104; i_577_++) {
						for (int i_578_ = 0; i_578_ < 104; i_578_++) {
							aDequeArrayArrayArray1323[i_576_][i_577_][i_578_] = null;
						}
					}
				}
				aDeque_1261 = new Deque(true);
				anInt860 = 0;
				friendCount = 0;
				method44(Client.aBoolean1190, anInt1191);
				anInt1191 = -1;
				method44(Client.aBoolean1190, anInt988);
				anInt988 = -1;
				method44(Client.aBoolean1190, anInt1169);
				anInt1169 = -1;
				method44(Client.aBoolean1190, anInt1053);
				anInt1053 = -1;
				method44(Client.aBoolean1190, anInt960);
				anInt960 = -1;
				method44(Client.aBoolean1190, anInt1089);
				anInt1089 = -1;
				method44(Client.aBoolean1190, anInt1279);
				anInt1279 = -1;
				aBoolean1239 = false;
				anInt1285 = 3;
				anInt1244 = 0;
				aBoolean1065 = false;
				aBoolean866 = false;
				aString1058 = null;
				anInt1319 = 0;
				anInt1213 = -1;
				aBoolean1144 = true;
				method25(anInt1015);
				for (int i_579_ = 0; i_579_ < 5; i_579_++) {
					anIntArray1099[i_579_] = 0;
				}
				for (int i_580_ = 0; i_580_ < 5; i_580_++) {
					aStringArray1069[i_580_] = null;
					aBooleanArray1070[i_580_] = false;
				}
				Client.anInt1100 = 0;
				Client.anInt1165 = 0;
				Client.anInt1235 = 0;
				Client.anInt1052 = 0;
				Client.anInt1139 = 0;
				Client.anInt841 = 0;
				Client.anInt1230 = 0;
				Client.anInt1013 = 0;
				Client.anInt1049 = 0;
				Client.anInt1162 = 0;
				method122(-906);
			} else if (i_569_ == 3) {
				aString957 = "";
				aString958 = "Invalid username or password.";
			} else if (i_569_ == 4) {
				aString957 = "Your account has been disabled.";
				aString958 = "Please check your message-centre for details.";
			} else if (i_569_ == 5) {
				aString957 = "Your account is already logged in.";
				aString958 = "Try again in 60 secs...";
			} else if (i_569_ == 6) {
				aString957 = "RuneScape has been updated!";
				aString958 = "Please reload this page.";
			} else if (i_569_ == 7) {
				aString957 = "This world is full.";
				aString958 = "Please use a different world.";
			} else if (i_569_ == 8) {
				aString957 = "Unable to connect.";
				aString958 = "Login server offline.";
			} else if (i_569_ == 9) {
				aString957 = "Login limit exceeded.";
				aString958 = "Too many connections from your address.";
			} else if (i_569_ == 10) {
				aString957 = "Unable to connect.";
				aString958 = "Bad session id.";
			} else if (i_569_ == 12) {
				aString957 = "You need a members account to login to this world.";
				aString958 = "Please subscribe, or use a different world.";
			} else if (i_569_ == 13) {
				aString957 = "Could not complete login.";
				aString958 = "Please try using a different world.";
			} else if (i_569_ == 14) {
				aString957 = "The server is being updated.";
				aString958 = "Please wait 1 minute and try again.";
			} else if (i_569_ == 15) {
				aBoolean1137 = true;
				aPacket_964.offset = 0;
				inputStream.offset = 0;
				opcode = -1;
				anInt903 = -1;
				anInt904 = -1;
				anInt905 = -1;
				packetSize = 0;
				anInt871 = 0;
				anInt1057 = 0;
				anInt1183 = 0;
				aBoolean1065 = false;
				aLong1229 = System.currentTimeMillis();
			} else if (i_569_ == 16) {
				aString957 = "Login attempts exceeded.";
				aString958 = "Please wait 1 minute and try again.";
			} else if (i_569_ == 17) {
				aString957 = "You are standing in a members-only area.";
				aString958 = "To play on this world move to a free area first";
			} else if (i_569_ == 18) {
				aString957 = "Account locked as we suspect it has been stolen.";
				aString958 = "Press 'recover a locked account' on front page.";
			} else if (i_569_ == 20) {
				aString957 = "Invalid loginserver requested";
				aString958 = "Please try using a different world.";
			} else if (i_569_ == 21) {
				int i_581_ = socket.method225();
				for (i_581_ += 3; i_581_ >= 0; i_581_--) {
					aString957 = "You have only just left another world";
					aString958 = "Your profile will be transferred in: " + i_581_;
					method131(true);
					try {
						Thread.sleep(1200L);
					} catch (Exception exception) {
						/* empty */
					}
				}
				method79(string, string_567_, bool);
			} else if (i_569_ == 22) {
				aString957 = "Malformed login packet.";
				aString958 = "Please try again.";
			} else if (i_569_ == 23) {
				aString957 = "No reply from loginserver.";
				aString958 = "Please try again.";
			} else if (i_569_ == 24) {
				aString957 = "Error loading your profile.";
				aString958 = "Please contact customer support.";
			} else if (i_569_ == 25) {
				aString957 = "Unexpected loginserver response.";
				aString958 = "Please try using a different world.";
			} else if (i_569_ == 26) {
				aString957 = "This computers address has been blocked";
				aString958 = "as it was used to break our rules";
			} else if (i_569_ == -1) {
				if (i_570_ == 0) {
					if (anInt850 < 2) {
						try {
							Thread.sleep(2000L);
						} catch (Exception exception) {
							/* empty */
						}
						anInt850++;
						method79(string, string_567_, bool);
					} else {
						aString957 = "No response from loginserver";
						aString958 = "Please wait 1 minute and try again.";
					}
				} else {
					aString957 = "No response from server";
					aString958 = "Please try using a different world.";
				}
			} else {
				System.out.println("response:" + i_569_);
				aString957 = "Unexpected server response";
				aString958 = "Please try using a different world.";
			}
		} catch (IOException ioexception) {
			aString957 = "";
			aString958 = "Error connecting to server.";
		}
	}

	public final boolean method80(int i, int i_582_, int i_583_, int i_584_) {
		int i_585_ = i_584_ >> 14 & 0x7fff;
		int i_586_ = aClass22_1164.method271(anInt1091, i_583_, i, i_584_);
		if (i_586_ == -1) {
			return false;
		}
		int i_587_ = i_586_ & 0x1f;
		int i_588_ = i_586_ >> 6 & 0x3;
		if (i_587_ == 10 || i_587_ == 11 || i_587_ == 22) {
			ObjectDefinition objectDefinition = ObjectDefinition.method434(i_585_);
			int i_589_;
			int i_590_;
			if (i_588_ == 0 || i_588_ == 2) {
				i_589_ = objectDefinition.anInt801;
				i_590_ = objectDefinition.anInt775;
			} else {
				i_589_ = objectDefinition.anInt775;
				i_590_ = objectDefinition.anInt801;
			}
			int i_591_ = objectDefinition.anInt764;
			if (i_588_ != 0) {
				i_591_ = (i_591_ << i_588_ & 0xf) + (i_591_ >> 4 - i_588_);
			}
			method35(true, false, i,
				((ObjectInstance) Client.myPlayer).anIntArray1587[0], i_589_, i_590_,
				2, 0, i_583_, i_591_, 0,
				((ObjectInstance) Client.myPlayer).anIntArray1586[0]);
		} else {
			method35(true, false, i,
				((ObjectInstance) Client.myPlayer).anIntArray1587[0], 0, 0, 2,
				i_587_ + 1, i_583_, 0, i_588_,
				((ObjectInstance) Client.myPlayer).anIntArray1586[0]);
		}
		anInt1020 = anInt29;
		anInt1021 = anInt30;
		anInt1023 = 2;
		anInt1022 = 0;
		packetSize += i_582_;
		return true;
	}

	public final void method81(byte i) {
		int i_592_ = 256;
		for (int i_593_ = 10; i_593_ < 117; i_593_++) {
			int i_594_ = (int) (Math.random() * 100.0);
			if (i_594_ < 50) {
				anIntArray1084[i_593_ + (i_592_ - 2 << 7)] = 255;
			}
		}
		for (int i_595_ = 0; i_595_ < 100; i_595_++) {
			int i_596_ = (int) (Math.random() * 124.0) + 2;
			int i_597_ = (int) (Math.random() * 128.0) + 128;
			int i_598_ = i_596_ + (i_597_ << 7);
			anIntArray1084[i_598_] = 192;
		}
		for (int i_599_ = 1; i_599_ < i_592_ - 1; i_599_++) {
			for (int i_600_ = 1; i_600_ < 127; i_600_++) {
				int i_601_ = i_600_ + (i_599_ << 7);
				anIntArray1085[i_601_] = (anIntArray1084[i_601_ - 1] + anIntArray1084[i_601_ + 1]
					+ anIntArray1084[i_601_ - 128] + anIntArray1084[i_601_ + 128]) / 4;
			}
		}
		anInt1238 += 128;
		if (anInt1238 > anIntArray1176.length) {
			anInt1238 -= anIntArray1176.length;
			int i_602_ = (int) (Math.random() * 12.0);
			method83(aIndexedSpriteArray1117[i_602_], 0);
		}
		for (int i_603_ = 1; i_603_ < i_592_ - 1; i_603_++) {
			for (int i_604_ = 1; i_604_ < 127; i_604_++) {
				int i_605_ = i_604_ + (i_603_ << 7);
				int i_606_ = (anIntArray1085[i_605_ + 128] - anIntArray1176[(i_605_ + anInt1238 & anIntArray1176.length - 1)] / 5);
				if (i_606_ < 0) {
					i_606_ = 0;
				}
				anIntArray1084[i_605_] = i_606_;
			}
		}
		if (i == 1) {
			boolean bool = false;
		} else {
			for (int i_607_ = 1; i_607_ > 0; i_607_++) {
				/* empty */
			}
		}
		for (int i_608_ = 0; i_608_ < i_592_ - 1; i_608_++) {
			anIntArray1166[i_608_] = anIntArray1166[i_608_ + 1];
		}
		anIntArray1166[i_592_ - 1] = (int) (Math.sin((double) Client.anInt1325 / 14.0) * 16.0
			+ Math.sin((double) Client.anInt1325 / 15.0) * 14.0 + Math
			.sin((double) Client.anInt1325 / 16.0) * 12.0);
		if (anInt1047 > 0) {
			anInt1047 -= 4;
		}
		if (anInt1048 > 0) {
			anInt1048 -= 4;
		}
		if (anInt1047 == 0 && anInt1048 == 0) {
			int i_609_ = (int) (Math.random() * 2000.0);
			if (i_609_ == 0) {
				anInt1047 = 1024;
			}
			if (i_609_ == 1) {
				anInt1048 = 1024;
			}
		}
	}

	public final void method82(NpcDefinition npcDefinition, int i, int i_610_, int i_611_,
		byte i_612_) {
		if (i_612_ != -76) {
			aDequeArrayArrayArray1323 = null;
		}
		if (anInt1183 < 400) {
			if (npcDefinition.childIds != null) {
				npcDefinition = npcDefinition.method374();
			}
			if (npcDefinition != null && npcDefinition.aBoolean631) {
				String string = npcDefinition.examine;
				if (npcDefinition.anInt639 != 0) {
					string += Client.method92(npcDefinition.anInt639,
						(((Player) Client.myPlayer).anInt1753), 736)
						+ " (level-"
						+ npcDefinition.anInt639 + ")";
				}
				if (anInt1146 == 1) {
					aStringArray1184[anInt1183] = ("Use " + ((Client) this).aString1150
						+ " with @yel@" + string);
					anIntArray981[anInt1183] = 347;
					anIntArray982[anInt1183] = i_611_;
					anIntArray979[anInt1183] = i_610_;
					anIntArray980[anInt1183] = i;
					anInt1183++;
				} else if (anInt1171 == 1) {
					if ((anInt1173 & 0x2) == 2) {
						aStringArray1184[anInt1183] = ((Client) this).aString1174 + " @yel@"
							+ string;
						anIntArray981[anInt1183] = 67;
						anIntArray982[anInt1183] = i_611_;
						anIntArray979[anInt1183] = i_610_;
						anIntArray980[anInt1183] = i;
						anInt1183++;
					}
				} else {
					if (npcDefinition.aStringArray646 != null) {
						for (int i_613_ = 4; i_613_ >= 0; i_613_--) {
							if (npcDefinition.aStringArray646[i_613_] != null
								&& !npcDefinition.aStringArray646[i_613_]
									.equalsIgnoreCase("attack")) {
								aStringArray1184[anInt1183] = (npcDefinition.aStringArray646[i_613_]
									+ " @yel@" + string);
								if (i_613_ == 0) {
									anIntArray981[anInt1183] = 318;
								}
								if (i_613_ == 1) {
									anIntArray981[anInt1183] = 921;
								}
								if (i_613_ == 2) {
									anIntArray981[anInt1183] = 118;
								}
								if (i_613_ == 3) {
									anIntArray981[anInt1183] = 553;
								}
								if (i_613_ == 4) {
									anIntArray981[anInt1183] = 432;
								}
								anIntArray982[anInt1183] = i_611_;
								anIntArray979[anInt1183] = i_610_;
								anIntArray980[anInt1183] = i;
								anInt1183++;
							}
						}
					}
					if (npcDefinition.aStringArray646 != null) {
						for (int i_614_ = 4; i_614_ >= 0; i_614_--) {
							if (npcDefinition.aStringArray646[i_614_] != null
								&& npcDefinition.aStringArray646[i_614_].equalsIgnoreCase("attack")) {
								int i_615_ = 0;
								if (npcDefinition.anInt639 > (((Player) Client.myPlayer).anInt1753)) {
									i_615_ = 2000;
								}
								aStringArray1184[anInt1183] = (npcDefinition.aStringArray646[i_614_]
									+ " @yel@" + string);
								if (i_614_ == 0) {
									anIntArray981[anInt1183] = i_615_ + 318;
								}
								if (i_614_ == 1) {
									anIntArray981[anInt1183] = i_615_ + 921;
								}
								if (i_614_ == 2) {
									anIntArray981[anInt1183] = i_615_ + 118;
								}
								if (i_614_ == 3) {
									anIntArray981[anInt1183] = i_615_ + 553;
								}
								if (i_614_ == 4) {
									anIntArray981[anInt1183] = i_615_ + 432;
								}
								anIntArray982[anInt1183] = i_611_;
								anIntArray979[anInt1183] = i_610_;
								anIntArray980[anInt1183] = i;
								anInt1183++;
							}
						}
					}
					aStringArray1184[anInt1183] = "Examine @yel@" + string;
					anIntArray981[anInt1183] = 1668;
					anIntArray982[anInt1183] = i_611_;
					anIntArray979[anInt1183] = i_610_;
					anIntArray980[anInt1183] = i;
					anInt1183++;
				}
			}
		}
	}

	public final void method83(IndexedSprite class50_sub1_sub1_sub3, int i) {
		packetSize += i;
		int i_616_ = 256;
		for (int i_617_ = 0; i_617_ < anIntArray1176.length; i_617_++) {
			anIntArray1176[i_617_] = 0;
		}
		for (int i_618_ = 0; i_618_ < 5000; i_618_++) {
			int i_619_ = (int) (Math.random() * 128.0 * (double) i_616_);
			anIntArray1176[i_619_] = (int) (Math.random() * 256.0);
		}
		for (int i_620_ = 0; i_620_ < 20; i_620_++) {
			for (int i_621_ = 1; i_621_ < i_616_ - 1; i_621_++) {
				for (int i_622_ = 1; i_622_ < 127; i_622_++) {
					int i_623_ = i_622_ + (i_621_ << 7);
					anIntArray1177[i_623_] = (anIntArray1176[i_623_ - 1]
						+ anIntArray1176[i_623_ + 1] + anIntArray1176[i_623_ - 128] + anIntArray1176[i_623_ + 128]) / 4;
				}
			}
			int[] is = anIntArray1176;
			anIntArray1176 = anIntArray1177;
			anIntArray1177 = is;
		}
		if (class50_sub1_sub1_sub3 != null) {
			int i_624_ = 0;
			for (int i_625_ = 0; i_625_ < class50_sub1_sub1_sub3.anInt1519; i_625_++) {
				for (int i_626_ = 0; i_626_ < class50_sub1_sub1_sub3.width; i_626_++) {
					if (class50_sub1_sub1_sub3.pixels[i_624_++] != 0) {
						int i_627_ = i_626_ + 16 + class50_sub1_sub1_sub3.anInt1520;
						int i_628_ = i_625_ + 16 + class50_sub1_sub1_sub3.anInt1521;
						int i_629_ = i_627_ + (i_628_ << 7);
						anIntArray1176[i_629_] = 0;
					}
				}
			}
		}
	}

	public final void method84(int i) {
		aGraphicsBuffer_1159.method230(false);
		Renderer3D.anIntArray1538 = anIntArray1000;
		chatback.method501(0, 0);
		if (aBoolean866) {
			aFont_1061.method481(239, 452, 40, 0, aString937);
			aFont_1061.method481(239, 452, 60, 128, aString1026 + "*");
		} else if (anInt1244 == 1) {
			aFont_1061.method481(239, 452, 40, 0, "Enter amount:");
			aFont_1061.method481(239, 452, 60, 128, aString949 + "*");
		} else if (anInt1244 == 2) {
			aFont_1061.method481(239, 452, 40, 0, "Enter name:");
			aFont_1061.method481(239, 452, 60, 128, aString949 + "*");
		} else if (anInt1244 == 3) {
			if (aString949 != aString861) {
				method14(aString949, 2);
				aString861 = aString949;
			}
			Font font = aFont_1060;
			Renderer2D.method457(0, 0, 77, 463, true);
			for (int i_630_ = 0; i_630_ < anInt862; i_630_++) {
				int i_631_ = i_630_ * 14 + 18 - anInt865;
				if (i_631_ > 0 && i_631_ < 110) {
					font.method481(239, 452, i_631_, 0, aStringArray863[i_630_]);
				}
			}
			Renderer2D.method456();
			if (anInt862 > 5) {
				method56(true, anInt865, 463, 77, anInt862 * 14 + 7, 0);
			}
			if (aString949.length() == 0) {
				aFont_1061.method481(239, 452, 40, 255, "Enter object name");
			} else if (anInt862 == 0) {
				aFont_1061.method481(239, 452, 40, 0,
					"No matching objects found, please shorten search");
			}
			font.method481(239, 452, 90, 0, aString949 + "*");
			Renderer2D.method463(0, 0, 77, 479, true);
		} else if (aString1058 != null) {
			aFont_1061.method481(239, 452, 40, 0, aString1058);
			aFont_1061.method481(239, 452, 60, 128, "Click to continue");
		} else if (anInt988 != -1) {
			method142(0, 0, Interface.method195(anInt988), 0, 8);
		} else if (anInt1191 != -1) {
			method142(0, 0, Interface.method195(anInt1191), 0, 8);
		} else {
			Font font = aFont_1060;
			int i_632_ = 0;
			Renderer2D.method457(0, 0, 77, 463, true);
			for (int i_633_ = 0; i_633_ < 100; i_633_++) {
				if (aStringArray1298[i_633_] != null) {
					int i_634_ = anIntArray1296[i_633_];
					int i_635_ = 70 - i_632_ * 14 + anInt851;
					String string = aStringArray1297[i_633_];
					int i_636_ = 0;
					if (string != null && string.startsWith("@cr1@")) {
						string = string.substring(5);
						i_636_ = 1;
					}
					if (string != null && string.startsWith("@cr2@")) {
						string = string.substring(5);
						i_636_ = 2;
					}
					if (i_634_ == 0) {
						if (i_635_ > 0 && i_635_ < 110) {
							font.method485(2245, 4, 0, i_635_, (aStringArray1298[i_633_]));
						}
						i_632_++;
					}
					if ((i_634_ == 1 || i_634_ == 2)
						&& (i_634_ == 1 || anInt1006 == 0 || anInt1006 == 1
							&& method148(13292, string))) {
						if (i_635_ > 0 && i_635_ < 110) {
							int i_637_ = 4;
							if (i_636_ == 1) {
								mod_icons[0].method501(i_635_ - 12, i_637_);
								i_637_ += 14;
							}
							if (i_636_ == 2) {
								mod_icons[1].method501(i_635_ - 12, i_637_);
								i_637_ += 14;
							}
							font.method485(2245, i_637_, 0, i_635_, string + ":");
							i_637_ += font.method483((byte) 35, string) + 8;
							font.method485(2245, i_637_, 255, i_635_, (aStringArray1298[i_633_]));
						}
						i_632_++;
					}
					if ((i_634_ == 3 || i_634_ == 7)
						&& anInt1223 == 0
						&& (i_634_ == 7 || anInt887 == 0 || anInt887 == 1
							&& method148(13292, string))) {
						if (i_635_ > 0 && i_635_ < 110) {
							int i_638_ = 4;
							font.method485(2245, i_638_, 0, i_635_, "From");
							i_638_ += font.method483((byte) 35, "From ");
							if (i_636_ == 1) {
								mod_icons[0].method501(i_635_ - 12, i_638_);
								i_638_ += 14;
							}
							if (i_636_ == 2) {
								mod_icons[1].method501(i_635_ - 12, i_638_);
								i_638_ += 14;
							}
							font.method485(2245, i_638_, 0, i_635_, string + ":");
							i_638_ += font.method483((byte) 35, string) + 8;
							font.method485(2245, i_638_, 8388608, i_635_,
								(aStringArray1298[i_633_]));
						}
						i_632_++;
					}
					if (i_634_ == 4
						&& (anInt1227 == 0 || anInt1227 == 1 && method148(13292, string))) {
						if (i_635_ > 0 && i_635_ < 110) {
							font.method485(2245, 4, 8388736, i_635_, string + " "
								+ aStringArray1298[i_633_]);
						}
						i_632_++;
					}
					if (i_634_ == 5 && anInt1223 == 0 && anInt887 < 2) {
						if (i_635_ > 0 && i_635_ < 110) {
							font.method485(2245, 4, 8388608, i_635_, (aStringArray1298[i_633_]));
						}
						i_632_++;
					}
					if (i_634_ == 6 && anInt1223 == 0 && anInt887 < 2) {
						if (i_635_ > 0 && i_635_ < 110) {
							font.method485(2245, 4, 0, i_635_, ("To " + string + ":"));
							font.method485(2245, (12 + font.method483((byte) 35, "To " + string)),
								8388608, i_635_, aStringArray1298[i_633_]);
						}
						i_632_++;
					}
					if (i_634_ == 8
						&& (anInt1227 == 0 || anInt1227 == 1 && method148(13292, string))) {
						if (i_635_ > 0 && i_635_ < 110) {
							font.method485(2245, 4, 8270336, i_635_, string + " "
								+ aStringArray1298[i_633_]);
						}
						i_632_++;
					}
				}
			}
			Renderer2D.method456();
			anInt1107 = i_632_ * 14 + 7;
			if (anInt1107 < 78) {
				anInt1107 = 78;
			}
			method56(true, anInt1107 - anInt851 - 77, 463, 77, anInt1107, 0);
			String string;
			if (Client.myPlayer != null && ((Player) Client.myPlayer).aString1751 != null) {
				string = ((Player) Client.myPlayer).aString1751;
			} else {
				string = TextUtil.method303(aString1092);
			}
			font.method485(2245, 4, 0, 90, string + ":");
			font.method485(2245, 6 + font.method483((byte) 35, string + ": "), 255, 90, aString1104
				+ "*");
			Renderer2D.method463(0, 0, 77, 479, true);
		}
		if (aBoolean1065 && anInt1304 == 2) {
			method128(false);
		}
		aGraphicsBuffer_1159.method231(357, 17, aGraphics14, aBoolean1074);
		aGraphicsBuffer_1158.method230(false);
		Renderer3D.anIntArray1538 = anIntArray1002;
		if (i != 0) {
			aDequeArrayArrayArray1323 = null;
		}
	}

	public final void method85(int i) {
		for (int i_639_ = -1; i_639_ < playerCount; i_639_++) {
			int i_640_;
			if (i_639_ == -1) {
				i_640_ = anInt969;
			} else {
				i_640_ = ((Client) this).playerIndices[i_639_];
			}
			Player player = totalPlayers[i_640_];
			if (player != null && (((ObjectInstance) player).anInt1582) > 0) {
				((ObjectInstance) player).anInt1582--;
				if ((((ObjectInstance) player).anInt1582) == 0) {
					((ObjectInstance) player).aString1580 = null;
				}
			}
		}
		packetSize += i;
		for (int i_641_ = 0; i_641_ < npcCount; i_641_++) {
			int i_642_ = ((Client) this).anIntArray1134[i_641_];
			Npc npc = totalNpcs[i_642_];
			if (npc != null && (((ObjectInstance) npc).anInt1582) > 0) {
				((ObjectInstance) npc).anInt1582--;
				if ((((ObjectInstance) npc).anInt1582) == 0) {
					((ObjectInstance) npc).aString1580 = null;
				}
			}
		}
	}

	public final void method86() {
		try {
			int i = 5;
			anIntArray837[8] = 0;
			int i_644_ = 0;
			while (anIntArray837[8] == 0) {
				String string = "Unknown problem";
				drawLoadingText(20, "Connecting to web server");
				for (int i_ = 0; i_ < 9; i_++) {
					anIntArray837[i_] = (int) Math.pow(0x89321, i);
				}
				/*
				 * try {
				 * DataInputStream datainputstream = method31("crc"
				 * + (int) (Math.random() * 9.9999999E7) + "-" + 377);
				 * Packet class50_sub1_sub2 = new Packet(true, new byte[40]);
				 * datainputstream.readFully(class50_sub1_sub2.aByteArray1453, 0, 40);
				 * datainputstream.close();
				 * for (int i_645_ = 0; i_645_ < 9; i_645_++) {
				 * anIntArray837[i_645_] = class50_sub1_sub2.method537();
				 * }
				 * int i_646_ = class50_sub1_sub2.method537();
				 * int i_647_ = 1234;
				 * for (int i_648_ = 0; i_648_ < 9; i_648_++) {
				 * i_647_ = (i_647_ << 1) + anIntArray837[i_648_];
				 * }
				 * if (i_646_ != i_647_) {
				 * string = "checksum problem";
				 * anIntArray837[8] = 0;
				 * }
				 * } catch (java.io.EOFException eofexception) {
				 * string = "EOF problem";
				 * anIntArray837[8] = 0;
				 * } catch (IOException ioexception) {
				 * string = "connection problem";
				 * anIntArray837[8] = 0;
				 * } catch (Exception exception) {
				 * string = "logic problem";
				 * anIntArray837[8] = 0;
				 * if (!Signlink.reporterror) {
				 * break;
				 * }
				 * }
				 */
				if (anIntArray837[8] == 0) {
					i_644_++;
					for (int i_649_ = i; i_649_ > 0; i_649_--) {
						if (i_644_ >= 10) {
							drawLoadingText(10, "Game updated - please reload page");
							i_649_ = 10;
						} else {
							drawLoadingText(10, (string + " - Will retry in " + i_649_ + " secs."));
						}
						try {
							Thread.sleep(1000L);
						} catch (Exception exception) {
						}
					}
					i *= 2;
					if (i > 60) {
						i = 60;
					}
					aBoolean900 = !aBoolean900;
				}
			}
		} catch (RuntimeException runtimeexception) {
			Signlink.reporterror("76789, " + runtimeexception.toString());
			throw new RuntimeException();
		}
	}

	public final void method87(int i) {
		aGraphicsBuffer_1157.method230(false);
		if (anInt1050 == 2) {
			byte[] is = mapback.pixels;
			int[] is_650_ = Renderer2D.pixels;
			int i_651_ = is.length;
			for (int i_652_ = 0; i_652_ < i_651_; i_652_++) {
				if (is[i_652_] == 0) {
					is_650_[i_652_] = 0;
				}
			}
			compass.method476(0, 567, 33, 25, 33, anIntArray1286, 0, anInt1252, 256,
				anIntArray1180, 25);
			aGraphicsBuffer_1158.method230(false);
			Renderer3D.anIntArray1538 = anIntArray1002;
		} else {
			int i_653_ = anInt1252 + anInt916 & 0x7ff;
			int i_654_ = (((ObjectInstance) Client.myPlayer).anInt1610) / 32 + 48;
			i = 58 / i;
			int i_655_ = 464 - ((ObjectInstance) Client.myPlayer).anInt1611 / 32;
			aSprite_1122.method476(5, 567, 151, i_654_, 146, anIntArray920, 25, i_653_,
				anInt1233 + 256, anIntArray1019, i_655_);
			compass.method476(0, 567, 33, 25, 33, anIntArray1286, 0, anInt1252, 256,
				anIntArray1180, 25);
			for (int i_656_ = 0; i_656_ < anInt1076; i_656_++) {
				i_654_ = (anIntArray1077[i_656_] * 4 + 2 - ((ObjectInstance) Client.myPlayer).anInt1610 / 32);
				i_655_ = (anIntArray1078[i_656_] * 4 + 2 - ((ObjectInstance) Client.myPlayer).anInt1611 / 32);
				method130(i_655_, true, aSpriteArray1278[i_656_], i_654_);
			}
			for (int i_657_ = 0; i_657_ < 104; i_657_++) {
				for (int i_658_ = 0; i_658_ < 104; i_658_++) {
					Deque deque = (aDequeArrayArrayArray1323[anInt1091][i_657_][i_658_]);
					if (deque != null) {
						i_654_ = (i_657_ * 4 + 2 - (((ObjectInstance) Client.myPlayer).anInt1610) / 32);
						i_655_ = (i_658_ * 4 + 2 - (((ObjectInstance) Client.myPlayer).anInt1611) / 32);
						method130(i_655_, true, aSprite_1192, i_654_);
					}
				}
			}
			for (int i_659_ = 0; i_659_ < npcCount; i_659_++) {
				Npc npc = (totalNpcs[((Client) this).anIntArray1134[i_659_]]);
				if (npc != null && npc.method576(0)) {
					NpcDefinition npcDefinition = (((Npc) npc).npc);
					if (npcDefinition.childIds != null) {
						npcDefinition = npcDefinition.method374();
					}
					if (npcDefinition != null && npcDefinition.aBoolean636
						&& npcDefinition.aBoolean631) {
						i_654_ = (((ObjectInstance) npc).anInt1610 / 32 - (((ObjectInstance) Client.myPlayer).anInt1610) / 32);
						i_655_ = (((ObjectInstance) npc).anInt1611 / 32 - (((ObjectInstance) Client.myPlayer).anInt1611) / 32);
						method130(i_655_, true, aSprite_1193, i_654_);
					}
				}
			}
			for (int i_660_ = 0; i_660_ < playerCount; i_660_++) {
				Player player = (totalPlayers[((Client) this).playerIndices[i_660_]]);
				if (player != null && player.method576(0)) {
					i_654_ = (((ObjectInstance) player).anInt1610 / 32 - (((ObjectInstance) Client.myPlayer).anInt1610 / 32));
					i_655_ = (((ObjectInstance) player).anInt1611 / 32 - (((ObjectInstance) Client.myPlayer).anInt1611 / 32));
					boolean bool = false;
					long l = TextUtil.method299(((Player) player).aString1751);
					for (int i_661_ = 0; i_661_ < friendCount; i_661_++) {
						if (l == friendNameForLong[i_661_] && friendNodeIds[i_661_] != 0) {
							bool = true;
							break;
						}
					}
					boolean bool_662_ = false;
					if (((Player) Client.myPlayer).anInt1766 != 0
						&& ((Player) player).anInt1766 != 0
						&& (((Player) Client.myPlayer).anInt1766 == ((Player) player).anInt1766)) {
						bool_662_ = true;
					}
					if (bool) {
						method130(i_655_, true, aSprite_1195, i_654_);
					} else if (bool_662_) {
						method130(i_655_, true, aSprite_1196, i_654_);
					} else {
						method130(i_655_, true, aSprite_1194, i_654_);
					}
				}
			}
			if (anInt1197 != 0 && Client.anInt1325 % 20 < 10) {
				if (anInt1197 == 1 && anInt1226 >= 0 && (anInt1226 < totalNpcs.length)) {
					Npc npc = totalNpcs[anInt1226];
					if (npc != null) {
						i_654_ = (((ObjectInstance) npc).anInt1610 / 32 - (((ObjectInstance) Client.myPlayer).anInt1610) / 32);
						i_655_ = (((ObjectInstance) npc).anInt1611 / 32 - (((ObjectInstance) Client.myPlayer).anInt1611) / 32);
						method55(i_655_, aSprite_1037, -687, i_654_);
					}
				}
				if (anInt1197 == 2) {
					i_654_ = ((anInt844 - anInt1040) * 4 + 2 - (((ObjectInstance) Client.myPlayer).anInt1610 / 32));
					i_655_ = ((anInt845 - anInt1041) * 4 + 2 - (((ObjectInstance) Client.myPlayer).anInt1611 / 32));
					method55(i_655_, aSprite_1037, -687, i_654_);
				}
				if (anInt1197 == 10 && anInt1151 >= 0 && (anInt1151 < totalPlayers.length)) {
					Player player = totalPlayers[anInt1151];
					if (player != null) {
						i_654_ = (((ObjectInstance) player).anInt1610 / 32 - (((ObjectInstance) Client.myPlayer).anInt1610) / 32);
						i_655_ = (((ObjectInstance) player).anInt1611 / 32 - (((ObjectInstance) Client.myPlayer).anInt1611) / 32);
						method55(i_655_, aSprite_1037, -687, i_654_);
					}
				}
			}
			if (anInt1120 != 0) {
				i_654_ = anInt1120 * 4 + 2
					- (((ObjectInstance) Client.myPlayer).anInt1610) / 32;
				i_655_ = anInt1121 * 4 + 2
					- (((ObjectInstance) Client.myPlayer).anInt1611) / 32;
				method130(i_655_, true, aSprite_1036, i_654_);
			}
			Renderer2D.method460(3, 78, 16777215, (byte) -24, 3, 97);
			aGraphicsBuffer_1158.method230(false);
			Renderer3D.anIntArray1538 = anIntArray1002;
		}
	}

	public final URL getCodeBase() {
		if (Signlink.mainapp != null) {
			return Signlink.mainapp.getCodeBase();
		}
		try {
			if (frame != null) {
				return new URL("http://127.0.0.1:" + (Client.anInt924 + 80));
			}
		} catch (Exception exception) {
			/* empty */
		}
		return super.getCodeBase();
	}

	public final boolean method88(int i, int i_663_, byte i_664_) {
		boolean bool = false;
		Interface iComponent = Interface.method195(i_663_);
		for (int element : iComponent.anIntArray258) {
			if (element == -1) {
				break;
			}
			Interface iComponent_666_ = Interface.method195(element);
			if (iComponent_666_.anInt236 == 0) {
				bool |= method88(i, iComponent_666_.anInt215, (byte) 5);
			}
			if (iComponent_666_.anInt236 == 6
				&& (iComponent_666_.anInt286 != -1 || iComponent_666_.anInt287 != -1)) {
				boolean bool_667_ = method95(iComponent_666_, -693);
				int i_668_;
				if (bool_667_) {
					i_668_ = iComponent_666_.anInt287;
				} else {
					i_668_ = iComponent_666_.anInt286;
				}
				if (i_668_ != -1) {
					Sequence sequence = Sequence.sequences[i_668_];
					iComponent_666_.anInt227 += i;
					while (iComponent_666_.anInt227 > sequence.method205(0,
						iComponent_666_.anInt235)) {
						iComponent_666_.anInt227 -= sequence
							.method205(0, iComponent_666_.anInt235);
						iComponent_666_.anInt235++;
						if (iComponent_666_.anInt235 >= sequence.anInt294) {
							iComponent_666_.anInt235 -= sequence.anInt298;
							if (iComponent_666_.anInt235 < 0
								|| iComponent_666_.anInt235 >= sequence.anInt294) {
								iComponent_666_.anInt235 = 0;
							}
						}
						bool = true;
					}
				}
			}
			if (iComponent_666_.anInt236 == 6 && iComponent_666_.anInt218 != 0) {
				int i_669_ = iComponent_666_.anInt218 >> 16;
				int i_670_ = iComponent_666_.anInt218 << 16 >> 16;
				i_669_ *= i;
				i_670_ *= i;
				iComponent_666_.anInt252 = iComponent_666_.anInt252 + i_669_ & 0x7ff;
				iComponent_666_.anInt253 = iComponent_666_.anInt253 + i_670_ & 0x7ff;
				bool = true;
			}
		}
		if (i_664_ == 5) {
			boolean bool_671_ = false;
		} else {
			anInt1236 = -424;
		}
		return bool;
	}

	public final String method89(int i, int i_672_) {
		if (i_672_ < 8 || i_672_ > 8) {
			throw new NullPointerException();
		}
		if (i < 999999999) {
			return String.valueOf(i);
		}
		return "*";
	}

	public final void method90(int i, long l) {
		if (i != -916) {
			opcode = inputStream.getUByte();
		}
		if (l != 0L) {
			if (anInt855 >= 100) {
				sendMessage("", "Your ignore list is full. Max of 100 hit", 0);
			} else {
				String string = TextUtil.method303(TextUtil.method300(l, 0));
				for (int i_673_ = 0; i_673_ < anInt855; i_673_++) {
					if (aLongArray1073[i_673_] == l) {
						sendMessage("", string + " is already on your ignore list", 0);
						return;
					}
				}
				for (int i_674_ = 0; i_674_ < friendCount; i_674_++) {
					if (friendNameForLong[i_674_] == l) {
						sendMessage("", ("Please remove " + string + " from your friend list first"), 0);
						return;
					}
				}
				aLongArray1073[anInt855++] = l;
				drawInventoryRequest = true;
				aPacket_964.putOpcode(217);
				aPacket_964.putLong(l);
			}
		}
	}

	public final void method7() {
		if (!aBoolean1016 && !aBoolean1283 && !aBoolean1097) {
			Client.anInt1325++;
		}
	}

	public final void method91(int i) {
		if (anInt1113 == 0) {
			aStringArray1184[0] = "Cancel";
			anIntArray981[0] = 1016;
			anInt1183 = 1;
			if (i >= 0) {
				anInt1004 = cryption.getNextKey();
			}
			if (anInt1053 != -1) {
				anInt915 = 0;
				anInt1315 = 0;
				method66(0, Interface.method195(anInt1053), 0, 0, 0, anInt22, 23658, anInt23);
				if (anInt915 != anInt1302) {
					anInt1302 = anInt915;
				}
				if (anInt1315 != anInt1129) {
					anInt1129 = anInt1315;
				}
			} else {
				method111(anInt1178);
				anInt915 = 0;
				anInt1315 = 0;
				if (anInt22 > 4 && anInt23 > 4 && anInt22 < 516 && anInt23 < 338) {
					if (anInt1169 != -1) {
						method66(4, Interface.method195(anInt1169), 0, 0, 4, anInt22, 23658,
							anInt23);
					} else {
						method43((byte) 7);
					}
				}
				if (anInt915 != anInt1302) {
					anInt1302 = anInt915;
				}
				if (anInt1315 != anInt1129) {
					anInt1129 = anInt1315;
				}
				anInt915 = 0;
				anInt1315 = 0;
				if (anInt22 > 553 && anInt23 > 205 && anInt22 < 743 && anInt23 < 466) {
					if (anInt1089 != -1) {
						method66(205, Interface.method195(anInt1089), 1, 0, 553, anInt22, 23658,
							anInt23);
					} else if (anIntArray1081[anInt1285] != -1) {
						method66(205, Interface.method195(anIntArray1081[anInt1285]), 1, 0, 553,
							anInt22, 23658, anInt23);
					}
				}
				if (anInt915 != anInt1280) {
					drawInventoryRequest = true;
					anInt1280 = anInt915;
				}
				if (anInt1315 != anInt1044) {
					drawInventoryRequest = true;
					anInt1044 = anInt1315;
				}
				anInt915 = 0;
				anInt1315 = 0;
				if (anInt22 > 17 && anInt23 > 357 && anInt22 < 496 && anInt23 < 453) {
					if (anInt988 != -1) {
						method66(357, Interface.method195(anInt988), 2, 0, 17, anInt22, 23658,
							anInt23);
					} else if (anInt1191 != -1) {
						method66(357, Interface.method195(anInt1191), 3, 0, 17, anInt22, 23658,
							anInt23);
					} else if (anInt23 < 434 && anInt22 < 426 && anInt1244 == 0) {
						method113(466, anInt22 - 17, anInt23 - 357);
					}
				}
				if ((anInt988 != -1 || anInt1191 != -1) && anInt915 != anInt1106) {
					aBoolean1240 = true;
					anInt1106 = anInt915;
				}
				if ((anInt988 != -1 || anInt1191 != -1) && anInt1315 != anInt1284) {
					aBoolean1240 = true;
					anInt1284 = anInt1315;
				}
				boolean bool = false;
				while (!bool) {
					bool = true;
					for (int i_675_ = 0; i_675_ < anInt1183 - 1; i_675_++) {
						if (anIntArray981[i_675_] < 1000 && anIntArray981[i_675_ + 1] > 1000) {
							String string = aStringArray1184[i_675_];
							aStringArray1184[i_675_] = aStringArray1184[i_675_ + 1];
							aStringArray1184[i_675_ + 1] = string;
							int i_676_ = anIntArray981[i_675_];
							anIntArray981[i_675_] = anIntArray981[i_675_ + 1];
							anIntArray981[i_675_ + 1] = i_676_;
							i_676_ = anIntArray979[i_675_];
							anIntArray979[i_675_] = anIntArray979[i_675_ + 1];
							anIntArray979[i_675_ + 1] = i_676_;
							i_676_ = anIntArray980[i_675_];
							anIntArray980[i_675_] = anIntArray980[i_675_ + 1];
							anIntArray980[i_675_ + 1] = i_676_;
							i_676_ = anIntArray982[i_675_];
							anIntArray982[i_675_] = anIntArray982[i_675_ + 1];
							anIntArray982[i_675_ + 1] = i_676_;
							bool = false;
						}
					}
				}
			}
		}
	}

	public static final String method92(int i, int i_677_, int i_678_) {
		if (i_678_ <= 0) {
			throw new NullPointerException();
		}
		int i_679_ = i_677_ - i;
		if (i_679_ < -9) {
			return "@red@";
		}
		if (i_679_ < -6) {
			return "@or3@";
		}
		if (i_679_ < -3) {
			return "@or2@";
		}
		if (i_679_ < 0) {
			return "@or1@";
		}
		if (i_679_ > 9) {
			return "@gre@";
		}
		if (i_679_ > 6) {
			return "@gr3@";
		}
		if (i_679_ > 3) {
			return "@gr2@";
		}
		if (i_679_ > 0) {
			return "@gr1@";
		}
		return "@yel@";
	}

	public final void method93(int i) {
		try {
			anInt1276 = -1;
			aDeque_1210.method162();
			aDeque_1282.method162();
			Renderer3D.method506((byte) 71);
			method49(383);
			aClass22_1164.method241((byte) 7);
			System.gc();
			for (int i_680_ = 0; i_680_ < 4; i_680_++) {
				aCollisionMapArray1260[i_680_].method422();
			}
			for (int i_681_ = 0; i_681_ < 4; i_681_++) {
				for (int i_682_ = 0; i_682_ < 104; i_682_++) {
					for (int i_683_ = 0; i_683_ < 104; i_683_++) {
						aByteArrayArrayArray1125[i_681_][i_682_][i_683_] = (byte) 0;
					}
				}
			}
			Class8 class8 = new Class8(anIntArrayArrayArray891, 14290, aByteArrayArrayArray1125,
				104, 104);
			int i_684_ = aByteArrayArray838.length;
			aPacket_964.putOpcode(40);
			if (!aBoolean1163) {
				for (int i_685_ = 0; i_685_ < i_684_; i_685_++) {
					int i_686_ = (anIntArray856[i_685_] >> 8) * 64 - anInt1040;
					int i_687_ = (anIntArray856[i_685_] & 0xff) * 64 - anInt1041;
					byte[] is = aByteArrayArray838[i_685_];
					if (is != null) {
						class8.method174(i_687_, false, (anInt890 - 6) * 8, i_686_, is,
							(anInt889 - 6) * 8, aCollisionMapArray1260);
					}
				}
				for (int i_688_ = 0; i_688_ < i_684_; i_688_++) {
					int i_689_ = (anIntArray856[i_688_] >> 8) * 64 - anInt1040;
					int i_690_ = (anIntArray856[i_688_] & 0xff) * 64 - anInt1041;
					byte[] is = aByteArrayArray838[i_688_];
					if (is == null && anInt890 < 800) {
						class8.method180(i_689_, i_690_, 64, -810, 64);
					}
				}
				aPacket_964.putOpcode(40);
				for (int i_691_ = 0; i_691_ < i_684_; i_691_++) {
					byte[] is = aByteArrayArray1232[i_691_];
					if (is != null) {
						int i_692_ = (anIntArray856[i_691_] >> 8) * 64 - anInt1040;
						int i_693_ = (anIntArray856[i_691_] & 0xff) * 64 - anInt1041;
						class8.method179(i_693_, aCollisionMapArray1260, i_692_, -571,
							aClass22_1164, is);
					}
				}
			}
			if (aBoolean1163) {
				for (int i_694_ = 0; i_694_ < 4; i_694_++) {
					for (int i_695_ = 0; i_695_ < 13; i_695_++) {
						for (int i_696_ = 0; i_696_ < 13; i_696_++) {
							boolean bool = false;
							int i_697_ = (anIntArrayArrayArray879[i_694_][i_695_][i_696_]);
							if (i_697_ != -1) {
								int i_698_ = i_697_ >> 24 & 0x3;
								int i_699_ = i_697_ >> 1 & 0x3;
								int i_700_ = i_697_ >> 14 & 0x3ff;
								int i_701_ = i_697_ >> 3 & 0x7ff;
								int i_702_ = (i_700_ / 8 << 8) + i_701_ / 8;
								for (int i_703_ = 0; i_703_ < anIntArray856.length; i_703_++) {
									if (anIntArray856[i_703_] == i_702_
										&& (aByteArrayArray838[i_703_] != null)) {
										class8.method168(i_699_, (i_701_ & 0x7) * 8, false,
											aByteArrayArray838[i_703_], i_694_, i_698_, i_695_ * 8,
											aCollisionMapArray1260, i_696_ * 8, (i_700_ & 0x7) * 8);
										bool = true;
										break;
									}
								}
							}
							if (!bool) {
								class8.method166(anInt1072, i_694_, i_696_ * 8, i_695_ * 8);
							}
						}
					}
				}
				for (int i_704_ = 0; i_704_ < 13; i_704_++) {
					for (int i_705_ = 0; i_705_ < 13; i_705_++) {
						int i_706_ = anIntArrayArrayArray879[0][i_704_][i_705_];
						if (i_706_ == -1) {
							class8.method180(i_704_ * 8, i_705_ * 8, 8, -810, 8);
						}
					}
				}
				aPacket_964.putOpcode(40);
				for (int i_707_ = 0; i_707_ < 4; i_707_++) {
					for (int i_708_ = 0; i_708_ < 13; i_708_++) {
						for (int i_709_ = 0; i_709_ < 13; i_709_++) {
							int i_710_ = (anIntArrayArrayArray879[i_707_][i_708_][i_709_]);
							if (i_710_ != -1) {
								int i_711_ = i_710_ >> 24 & 0x3;
								int i_712_ = i_710_ >> 1 & 0x3;
								int i_713_ = i_710_ >> 14 & 0x3ff;
								int i_714_ = i_710_ >> 3 & 0x7ff;
								int i_715_ = (i_713_ / 8 << 8) + i_714_ / 8;
								for (int i_716_ = 0; i_716_ < anIntArray856.length; i_716_++) {
									if (anIntArray856[i_716_] == i_715_
										&& (aByteArrayArray1232[i_716_] != null)) {
										class8.method172(i_707_, aCollisionMapArray1260,
											aClass22_1164, false, (aByteArrayArray1232[i_716_]),
											i_709_ * 8, i_712_, (i_713_ & 0x7) * 8, i_708_ * 8,
											(i_714_ & 0x7) * 8, i_711_);
										break;
									}
								}
							}
						}
					}
				}
			}
			aPacket_964.putOpcode(40);
			class8.method167(aCollisionMapArray1260, anInt1318, aClass22_1164);
			if (aGraphicsBuffer_1158 != null) {
				aGraphicsBuffer_1158.method230(false);
				Renderer3D.anIntArray1538 = anIntArray1002;
			}
			aPacket_964.putOpcode(40);
			int i_717_ = Class8.anInt150;
			if (i_717_ > anInt1091) {
				i_717_ = anInt1091;
			}
			if (i_717_ < anInt1091 - 1) {
				i_717_ = anInt1091 - 1;
			}
			if (Client.aBoolean926) {
				aClass22_1164.method242(Class8.anInt150, true);
			} else {
				aClass22_1164.method242(0, true);
			}
			for (int i_718_ = 0; i_718_ < 104; i_718_++) {
				for (int i_719_ = 0; i_719_ < 104; i_719_++) {
					method26(i_718_, i_719_);
				}
			}
			method18();
		} catch (Exception exception) {
			/* empty */
		}
		ObjectDefinition.aCache_779.method347();
		if (frame != null) {
			aPacket_964.putOpcode(78);
			aPacket_964.putInt(1057001181);
		}
		if (Client.aBoolean926 && Signlink.cache_dat != null) {
			int i_720_ = aClass32_Sub1_1291.method340(0, -31140);
			for (int i_721_ = 0; i_721_ < i_720_; i_721_++) {
				int i_722_ = aClass32_Sub1_1291.method325(i_721_, -493);
				if ((i_722_ & 0x79) == 0) {
					Model.method587(i_721_, 1);
				}
			}
		}
		System.gc();
		Renderer3D.method507((byte) 7, 20);
		aClass32_Sub1_1291.method336((byte) -125);
		int i_723_ = (anInt889 - 6) / 8 - 1;
		int i_724_ = (anInt889 + 6) / 8 + 1;
		int i_725_ = (anInt890 - 6) / 8 - 1;
		int i_726_ = (anInt890 + 6) / 8 + 1;
		i = 94 / i;
		if (aBoolean1067) {
			i_723_ = 49;
			i_724_ = 50;
			i_725_ = 49;
			i_726_ = 50;
		}
		for (int i_727_ = i_723_; i_727_ <= i_724_; i_727_++) {
			for (int i_728_ = i_725_; i_728_ <= i_726_; i_728_++) {
				if (i_727_ == i_723_ || i_727_ == i_724_ || i_728_ == i_725_ || i_728_ == i_726_) {
					int i_729_ = aClass32_Sub1_1291.method344(0, i_727_, i_728_, 0);
					if (i_729_ != -1) {
						aClass32_Sub1_1291.method337(i_729_, 3);
					}
					int i_730_ = aClass32_Sub1_1291.method344(0, i_727_, i_728_, 1);
					if (i_730_ != -1) {
						aClass32_Sub1_1291.method337(i_730_, 3);
					}
				}
			}
		}
	}

	public final void method94(int i, int i_731_, int i_732_, int i_733_, int i_734_, int i_735_,
		byte i_736_) {
		int i_737_ = 2048 - i_732_ & 0x7ff;
		int i_738_ = 2048 - i_734_ & 0x7ff;
		if (i_736_ != -103) {
			opcode = -1;
		}
		int i_739_ = 0;
		int i_740_ = 0;
		int i_741_ = i_733_;
		if (i_737_ != 0) {
			int i_742_ = Model.anIntArray1710[i_737_];
			int i_743_ = Model.anIntArray1711[i_737_];
			int i_744_ = i_740_ * i_743_ - i_741_ * i_742_ >> 16;
			i_741_ = i_740_ * i_742_ + i_741_ * i_743_ >> 16;
			i_740_ = i_744_;
		}
		if (i_738_ != 0) {
			int i_745_ = Model.anIntArray1710[i_738_];
			int i_746_ = Model.anIntArray1711[i_738_];
			int i_747_ = i_741_ * i_745_ + i_739_ * i_746_ >> 16;
			i_741_ = i_741_ * i_746_ - i_739_ * i_745_ >> 16;
			i_739_ = i_747_;
		}
		anInt1216 = i_731_ - i_739_;
		anInt1217 = i - i_740_;
		anInt1218 = i_735_ - i_741_;
		anInt1219 = i_732_;
		anInt1220 = i_734_;
	}

	public final boolean method95(Interface iComponent, int i) {
		if (i >= 0) {
			anInt1175 = 276;
		}
		if (iComponent.anIntArray273 == null) {
			return false;
		}
		for (int i_748_ = 0; i_748_ < iComponent.anIntArray273.length; i_748_++) {
			int i_749_ = method129(3, i_748_, iComponent);
			int i_750_ = iComponent.anIntArray256[i_748_];
			if (iComponent.anIntArray273[i_748_] == 2) {
				if (i_749_ >= i_750_) {
					return false;
				}
			} else if (iComponent.anIntArray273[i_748_] == 3) {
				if (i_749_ <= i_750_) {
					return false;
				}
			} else if (iComponent.anIntArray273[i_748_] == 4) {
				if (i_749_ == i_750_) {
					return false;
				}
			} else if (i_749_ != i_750_) {
				return false;
			}
		}
		return true;
	}

	private final void method96(int i, int i_751_, Packet packet) {
		anInt1294 = 0;
		anInt973 = 0;
		method41(i, aBoolean1274, packet);
		method114(i, -138, packet);
		i_751_ = 40 / i_751_;
		method16(i, (byte) 6, packet);
		method40(808, packet, i);
		for (int i_752_ = 0; i_752_ < anInt1294; i_752_++) {
			int i_753_ = ((Client) this).anIntArray1295[i_752_];
			if (((ObjectInstance) totalPlayers[i_753_]).anInt1585 != Client.anInt1325) {
				totalPlayers[i_753_] = null;
			}
		}
		if (packet.offset != i) {
			Signlink.reporterror("Error packet size mismatch in getplayer pos:" + packet.offset
				+ " psize:" + i);
			throw new RuntimeException("eek");
		}
		for (int i_754_ = 0; i_754_ < playerCount; i_754_++) {
			if ((totalPlayers[((Client) this).playerIndices[i_754_]]) == null) {
				Signlink.reporterror(aString1092 + " null entry in pl list - pos:" + i_754_
					+ " size:" + playerCount);
				throw new RuntimeException("eek");
			}
		}
	}

	public final void method97(int i, long l) {
		if (l != 0L) {
			for (int i_755_ = 0; i_755_ < anInt855; i_755_++) {
				if (aLongArray1073[i_755_] == l) {
					anInt855--;
					drawInventoryRequest = true;
					for (int i_756_ = i_755_; i_756_ < anInt855; i_756_++) {
						aLongArray1073[i_756_] = aLongArray1073[i_756_ + 1];
					}
					aPacket_964.putOpcode(160);
					aPacket_964.putLong(l);
					break;
				}
			}
			i = 42 / i;
		}
	}

	public final String getParameter(String string) {
		if (Signlink.mainapp != null) {
			return Signlink.mainapp.getParameter(string);
		}
		return super.getParameter(string);
	}

	public final void method98(int i) {
		int i_757_ = 256;
		if (anInt1047 > 0) {
			for (int i_758_ = 0; i_758_ < 256; i_758_++) {
				if (anInt1047 > 768) {
					anIntArray1310[i_758_] = method106(anIntArray1311[i_758_],
						anIntArray1312[i_758_], 1024 - anInt1047, 8);
				} else if (anInt1047 > 256) {
					anIntArray1310[i_758_] = anIntArray1312[i_758_];
				} else {
					anIntArray1310[i_758_] = method106(anIntArray1312[i_758_],
						anIntArray1311[i_758_], 256 - anInt1047, 8);
				}
			}
		} else if (anInt1048 > 0) {
			for (int i_759_ = 0; i_759_ < 256; i_759_++) {
				if (anInt1048 > 768) {
					anIntArray1310[i_759_] = method106(anIntArray1311[i_759_],
						anIntArray1313[i_759_], 1024 - anInt1048, 8);
				} else if (anInt1048 > 256) {
					anIntArray1310[i_759_] = anIntArray1313[i_759_];
				} else {
					anIntArray1310[i_759_] = method106(anIntArray1313[i_759_],
						anIntArray1311[i_759_], 256 - anInt1048, 8);
				}
			}
		} else {
			for (int i_760_ = 0; i_760_ < 256; i_760_++) {
				anIntArray1310[i_760_] = anIntArray1311[i_760_];
			}
		}
		for (int i_761_ = 0; i_761_ < 33920; i_761_++) {
			aGraphicsBuffer_1201.anIntArray392[i_761_] = aSprite_1017.pixels[i_761_];
		}
		int i_762_ = 0;
		int i_763_ = 1152;
		for (int i_764_ = 1; i_764_ < i_757_ - 1; i_764_++) {
			int i_765_ = anIntArray1166[i_764_] * (i_757_ - i_764_) / i_757_;
			int i_766_ = i_765_ + 22;
			if (i_766_ < 0) {
				i_766_ = 0;
			}
			i_762_ += i_766_;
			for (int i_767_ = i_766_; i_767_ < 128; i_767_++) {
				int i_768_ = anIntArray1084[i_762_++];
				if (i_768_ != 0) {
					int i_769_ = i_768_;
					int i_770_ = 256 - i_768_;
					i_768_ = anIntArray1310[i_768_];
					int i_771_ = aGraphicsBuffer_1201.anIntArray392[i_763_];
					aGraphicsBuffer_1201.anIntArray392[i_763_++] = ((((i_768_ & 0xff00ff) * i_769_ + (i_771_ & 0xff00ff)
						* i_770_) & ~0xff00ff) + (((i_768_ & 0xff00) * i_769_ + (i_771_ & 0xff00)
						* i_770_) & 0xff0000)) >> 8;
				} else {
					i_763_++;
				}
			}
			i_763_ += i_766_;
		}
		aGraphicsBuffer_1201.method231(0, 0, aGraphics14, aBoolean1074);
		i = 66 / i;
		for (int i_772_ = 0; i_772_ < 33920; i_772_++) {
			aGraphicsBuffer_1202.anIntArray392[i_772_] = aSprite_1018.pixels[i_772_];
		}
		i_762_ = 0;
		i_763_ = 1176;
		for (int i_773_ = 1; i_773_ < i_757_ - 1; i_773_++) {
			int i_774_ = anIntArray1166[i_773_] * (i_757_ - i_773_) / i_757_;
			int i_775_ = 103 - i_774_;
			i_763_ += i_774_;
			for (int i_776_ = 0; i_776_ < i_775_; i_776_++) {
				int i_777_ = anIntArray1084[i_762_++];
				if (i_777_ != 0) {
					int i_778_ = i_777_;
					int i_779_ = 256 - i_777_;
					i_777_ = anIntArray1310[i_777_];
					int i_780_ = aGraphicsBuffer_1202.anIntArray392[i_763_];
					aGraphicsBuffer_1202.anIntArray392[i_763_++] = ((((i_777_ & 0xff00ff) * i_778_ + (i_780_ & 0xff00ff)
						* i_779_) & ~0xff00ff) + (((i_777_ & 0xff00) * i_778_ + (i_780_ & 0xff00)
						* i_779_) & 0xff0000)) >> 8;
				} else {
					i_763_++;
				}
			}
			i_762_ += 128 - i_775_;
			i_763_ += 128 - i_775_ - i_774_;
		}
		aGraphicsBuffer_1202.method231(0, 637, aGraphics14, aBoolean1074);
	}

	public final void method99(boolean bool, byte i, int i_781_) {
		if (i != 8) {
			aPacket_964.putByte(49);
		}
		Signlink.midivol = i_781_;
		if (bool) {
			Signlink.midi = "voladjust";
		}
	}

	public final void method100(int i) {
		for (int i_782_ = -1; i_782_ < playerCount; i_782_++) {
			int i_783_;
			if (i_782_ == -1) {
				i_783_ = anInt969;
			} else {
				i_783_ = ((Client) this).playerIndices[i_782_];
			}
			Player player = totalPlayers[i_783_];
			if (player != null) {
				method68(1, (byte) -97, player);
			}
		}
		if (i < anInt1222 || i > anInt1222) {
			for (int i_784_ = 1; i_784_ > 0; i_784_++) {
				/* empty */
			}
		}
	}

	public static final void method101(boolean bool) {
		Class22.aBoolean451 = true;
		if (!bool) {
			Client.aBoolean1242 = !Client.aBoolean1242;
		}
		Renderer3D.aBoolean1527 = true;
		Client.aBoolean926 = true;
		Class8.aBoolean169 = true;
		ObjectDefinition.aBoolean772 = true;
	}

	public final void method102(long l, int i) {
		if (l != 0L) {
			if (friendCount >= 100 && anInt1068 != 1) {
				sendMessage("", "Your friendlist is full. Max of 100 for free users, and 200 for members", 0);
			} else if (friendCount >= 200) {
				sendMessage("", "Your friendlist is full. Max of 100 for free users, and 200 for members", 0);
			} else {
				String string = TextUtil.method303(TextUtil.method300(l, 0));
				for (int i_785_ = 0; i_785_ < friendCount; i_785_++) {
					if (friendNameForLong[i_785_] == l) {
						sendMessage("", string + " is already on your friend list", 0);
						return;
					}
				}
				for (int i_786_ = 0; i_786_ < anInt855; i_786_++) {
					if (aLongArray1073[i_786_] == l) {
						sendMessage("", ("Please remove " + string + " from your ignore list first"), 0);
						return;
					}
				}
				if (!string.equals(((Player) Client.myPlayer).aString1751)) {
					friendNames[friendCount] = string;
					if (i != -45229) {
						anInt1178 = -30;
					}
					friendNameForLong[friendCount] = l;
					friendNodeIds[friendCount] = 0;
					friendCount++;
					drawInventoryRequest = true;
					aPacket_964.putOpcode(120);
					aPacket_964.putLong(l);
				}
			}
		}
	}

	public final void method103(byte i, Interface iComponent) {
		if (i == 2) {
			boolean bool = false;
		} else {
			anInt1004 = -82;
		}
		int i_787_ = iComponent.anInt242;
		if (i_787_ >= 1 && i_787_ <= 100 || i_787_ >= 701 && i_787_ <= 800) {
			if (i_787_ == 1 && anInt860 == 0) {
				iComponent.aString230 = "Loading friend list";
				iComponent.anInt289 = 0;
			} else if (i_787_ == 1 && anInt860 == 1) {
				iComponent.aString230 = "Connecting to friendserver";
				iComponent.anInt289 = 0;
			} else if (i_787_ == 2 && anInt860 != 2) {
				iComponent.aString230 = "Please wait...";
				iComponent.anInt289 = 0;
			} else {
				int i_788_ = friendCount;
				if (anInt860 != 2) {
					i_788_ = 0;
				}
				if (i_787_ > 700) {
					i_787_ -= 601;
				} else {
					i_787_--;
				}
				if (i_787_ >= i_788_) {
					iComponent.aString230 = "";
					iComponent.anInt289 = 0;
				} else {
					iComponent.aString230 = friendNames[i_787_];
					iComponent.anInt289 = 1;
				}
			}
		} else if (i_787_ >= 101 && i_787_ <= 200 || i_787_ >= 801 && i_787_ <= 900) {
			int i_789_ = friendCount;
			if (anInt860 != 2) {
				i_789_ = 0;
			}
			if (i_787_ > 800) {
				i_787_ -= 701;
			} else {
				i_787_ -= 101;
			}
			if (i_787_ >= i_789_) {
				iComponent.aString230 = "";
				iComponent.anInt289 = 0;
			} else {
				if (friendNodeIds[i_787_] == 0) {
					iComponent.aString230 = "@red@Offline";
				} else if (friendNodeIds[i_787_] < 200) {
					if (friendNodeIds[i_787_] == Client.anInt923) {
						iComponent.aString230 = "@gre@World" + (friendNodeIds[i_787_] - 9);
					} else {
						iComponent.aString230 = "@yel@World" + (friendNodeIds[i_787_] - 9);
					}
				} else if (friendNodeIds[i_787_] == Client.anInt923) {
					iComponent.aString230 = "@gre@Classic" + (friendNodeIds[i_787_] - 219);
				} else {
					iComponent.aString230 = "@yel@Classic" + (friendNodeIds[i_787_] - 219);
				}
				iComponent.anInt289 = 1;
			}
		} else if (i_787_ == 203) {
			int i_790_ = friendCount;
			if (anInt860 != 2) {
				i_790_ = 0;
			}
			iComponent.anInt285 = i_790_ * 15 + 20;
			if (iComponent.anInt285 <= iComponent.anInt238) {
				iComponent.anInt285 = iComponent.anInt238 + 1;
			}
		} else if (i_787_ >= 401 && i_787_ <= 500) {
			i_787_ -= 401;
			if (i_787_ == 0 && anInt860 == 0) {
				iComponent.aString230 = "Loading ignore list";
				iComponent.anInt289 = 0;
			} else if (i_787_ == 1 && anInt860 == 0) {
				iComponent.aString230 = "Please wait...";
				iComponent.anInt289 = 0;
			} else {
				int i_791_ = anInt855;
				if (anInt860 == 0) {
					i_791_ = 0;
				}
				if (i_787_ >= i_791_) {
					iComponent.aString230 = "";
					iComponent.anInt289 = 0;
				} else {
					iComponent.aString230 = TextUtil.method303(TextUtil.method300(
						(aLongArray1073[i_787_]), 0));
					iComponent.anInt289 = 1;
				}
			}
		} else if (i_787_ == 503) {
			iComponent.anInt285 = anInt855 * 15 + 20;
			if (iComponent.anInt285 <= iComponent.anInt238) {
				iComponent.anInt285 = iComponent.anInt238 + 1;
			}
		} else if (i_787_ == 327) {
			iComponent.anInt252 = 150;
			iComponent.anInt253 = (int) (Math.sin((double) Client.anInt1325 / 40.0) * 256.0) & 0x7ff;
			if (aBoolean1277) {
				for (int i_792_ = 0; i_792_ < 7; i_792_++) {
					int i_793_ = anIntArray1326[i_792_];
					if (i_793_ >= 0 && !IdentityKit.appearances[i_793_].method447(256)) {
						return;
					}
				}
				aBoolean1277 = false;
				Model[] class50_sub1_sub4_sub4s = new Model[7];
				int i_794_ = 0;
				for (int i_795_ = 0; i_795_ < 7; i_795_++) {
					int i_796_ = anIntArray1326[i_795_];
					if (i_796_ >= 0) {
						class50_sub1_sub4_sub4s[i_794_++] = IdentityKit.appearances[i_796_]
							.method448((byte) 2);
					}
				}
				Model model = new Model(i_794_, class50_sub1_sub4_sub4s, (byte) -89);
				for (int i_797_ = 0; i_797_ < 5; i_797_++) {
					if (anIntArray1099[i_797_] != 0) {
						model.method602((Client.anIntArrayArray1008[i_797_][0]),
							(Client.anIntArrayArray1008[i_797_][(anIntArray1099[i_797_])]));
						if (i_797_ == 1) {
							model.method602(Client.anIntArray1268[0],
								(Client.anIntArray1268[(anIntArray1099[i_797_])]));
						}
					}
				}
				model.method595(7);
				model
					.method596(
						(Sequence.sequences[((ObjectInstance) Client.myPlayer).anInt1634].anIntArray295[0]),
						(byte) 6);
				model.preProcess(64, 850, -30, -50, -30, true);
				iComponent.anInt283 = 5;
				iComponent.anInt284 = 0;
				Interface.method201(5, model, 0, 6);
			}
		} else if (i_787_ == 324) {
			if (aSprite_1102 == null) {
				aSprite_1102 = iComponent.aSprite_212;
				aSprite_1103 = iComponent.aSprite_245;
			}
			if (aBoolean1144) {
				iComponent.aSprite_212 = aSprite_1103;
			} else {
				iComponent.aSprite_212 = aSprite_1102;
			}
		} else if (i_787_ == 325) {
			if (aSprite_1102 == null) {
				aSprite_1102 = iComponent.aSprite_212;
				aSprite_1103 = iComponent.aSprite_245;
			}
			if (aBoolean1144) {
				iComponent.aSprite_212 = aSprite_1102;
			} else {
				iComponent.aSprite_212 = aSprite_1103;
			}
		} else if (i_787_ == 600) {
			iComponent.aString230 = aString839;
			if (Client.anInt1325 % 20 < 10) {
				iComponent.aString230 += "|";
			} else {
				iComponent.aString230 += " ";
			}
		} else {
			if (i_787_ == 620) {
				if (anInt867 >= 1) {
					if (aBoolean1098) {
						iComponent.anInt240 = 16711680;
						iComponent.aString230 = "Moderator option: Mute player for 48 hours: <ON>";
					} else {
						iComponent.anInt240 = 16777215;
						iComponent.aString230 = "Moderator option: Mute player for 48 hours: <OFF>";
					}
				} else {
					iComponent.aString230 = "";
				}
			}
			if (i_787_ == 660) {
				int i_798_ = anInt1170 - anInt1215;
				String string;
				if (i_798_ <= 0) {
					string = "earlier today";
				} else if (i_798_ == 1) {
					string = "yesterday";
				} else {
					string = String.valueOf(i_798_) + " days ago";
				}
				iComponent.aString230 = ("You last logged in @red@" + string + "@bla@ from: @red@" + Signlink.dns);
			}
			if (i_787_ == 661) {
				if (anInt1034 == 0) {
					iComponent.aString230 = "\\nYou have not yet set any recovery questions.\\nIt is @lre@strongly@yel@ recommended that you do so.\\n\\nIf you don't you will be @lre@unable to recover your\\n@lre@password@yel@ if you forget it, or it is stolen.";
				} else if (anInt1034 <= anInt1170) {
					iComponent.aString230 = ("\\n\\nRecovery Questions Last Set:\\n@gre@" + method104(
						anInt1034, (byte) 83));
				} else {
					int i_799_ = anInt1170 + 14 - anInt1034;
					String string;
					if (i_799_ <= 0) {
						string = "Earlier today";
					} else if (i_799_ == 1) {
						string = "Yesterday";
					} else {
						string = String.valueOf(i_799_) + " days ago";
					}
					iComponent.aString230 = (string
						+ " you requested@lre@ new recovery\\n@lre@questions.@yel@ The requested change will occur\\non: @lre@"
						+ method104(anInt1034, (byte) 83) + "\\n\\nIf you do not remember making this request\\ncancel it immediately, and change your password.");
				}
			}
			if (i_787_ == 662) {
				String string;
				if (anInt1273 == 0) {
					string = "@yel@0 unread messages";
				} else if (anInt1273 == 1) {
					string = "@gre@1 unread message";
				} else {
					string = "@gre@" + anInt1273 + " unread messages";
				}
				iComponent.aString230 = "You have " + string + "\\nin your message centre.";
			}
			if (i_787_ == 663) {
				if (anInt1083 <= 0 || anInt1083 > anInt1170 + 10) {
					iComponent.aString230 = "Last password change:\\n@gre@Never changed";
				} else {
					iComponent.aString230 = ("Last password change:\\n@gre@" + method104(anInt1083,
						(byte) 83));
				}
			}
			if (i_787_ == 665) {
				if (anInt992 > 2 && !Client.aBoolean925) {
					iComponent.aString230 = "This is a non-members\\nworld. To enjoy your\\nmembers benefits we\\nrecommend you play on a\\nmembers world instead.";
				} else if (anInt992 > 2) {
					iComponent.aString230 = ("\\n\\nYou have @gre@" + anInt992 + "@yel@ days of\\nmember credit remaining.");
				} else if (anInt992 > 0) {
					iComponent.aString230 = ("You have @gre@" + anInt992 + "@yel@ days of\\nmember credit remaining.\\n\\n@lre@Credit low! Renew now\\n@lre@to avoid losing members.");
				} else {
					iComponent.aString230 = "You are not a member.\\n\\nChoose to subscribe and\\nyou'll get loads of extra\\nbenefits and features.";
				}
			}
			if (i_787_ == 667) {
				if (anInt992 > 2 && !Client.aBoolean925) {
					iComponent.aString230 = "To switch to a members-only world:\\n1) Logout and return to the world selection page.\\n2) Choose one of the members world with a gold star next to it's name.\\n\\nIf you prefer you can continue to use this world,\\nbut members only features will be unavailable here.";
				} else if (anInt992 > 0) {
					iComponent.aString230 = "To extend or cancel a subscription:\\n1) Logout and return to the frontpage of this website.\\n2)Choose the relevant option from the 'membership' section.\\n\\nNote: If you are a credit card subscriber a top-up payment will\\nautomatically be taken when 3 days credit remain.\\n(unless you cancel your subscription, which can be done at any time.)";
				} else {
					iComponent.aString230 = "To start a subscripton:\\n1) Logout and return to the frontpage of this website.\\n2) Choose 'Start a new subscription'";
				}
			}
			if (i_787_ == 668) {
				if (anInt1034 > anInt1170) {
					iComponent.aString230 = "To cancel this request:\\n1) Logout and return to the frontpage of this website.\\n2) Choose 'Cancel recovery questions'.";
				} else {
					iComponent.aString230 = "To change your recovery questions:\\n1) Logout and return to the frontpage of this website.\\n2) Choose 'Set new recovery questions'.";
				}
			}
		}
	}

	public final String method104(int i, byte i_800_) {
		if (i_800_ != 83) {
			opcode = inputStream.getUByte();
		}
		if (i > anInt1170 + 10) {
			return "Unknown";
		}
		long l = ((long) i + 11745L) * 86400000L;
		Calendar calendar = Calendar.getInstance();
		calendar.setTime(new Date(l));
		int i_801_ = calendar.get(5);
		int i_802_ = calendar.get(2);
		int i_803_ = calendar.get(1);
		String[] strings = { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct",
			"Nov", "Dec" };
		return String.valueOf(i_801_) + "-" + strings[i_802_] + "-" + i_803_;
	}

	public final void method105(int i, int i_804_) {
		packetSize += i;
		int i_805_ = Varp.varps[i_804_].anInt712;
		if (i_805_ != 0) {
			int i_806_ = anIntArray1039[i_804_];
			if (i_805_ == 1) {
				if (i_806_ == 1) {
					Renderer3D.method512(0.9, (byte) 6);
				}
				if (i_806_ == 2) {
					Renderer3D.method512(0.8, (byte) 6);
				}
				if (i_806_ == 3) {
					Renderer3D.method512(0.7, (byte) 6);
				}
				if (i_806_ == 4) {
					Renderer3D.method512(0.6, (byte) 6);
				}
				ItemDefinition.aCache_346.method347();
				aBoolean1046 = true;
			}
			if (i_805_ == 3) {
				boolean bool = aBoolean1266;
				if (i_806_ == 0) {
					method99(aBoolean1266, (byte) 8, 0);
					aBoolean1266 = true;
				}
				if (i_806_ == 1) {
					method99(aBoolean1266, (byte) 8, -400);
					aBoolean1266 = true;
				}
				if (i_806_ == 2) {
					method99(aBoolean1266, (byte) 8, -800);
					aBoolean1266 = true;
				}
				if (i_806_ == 3) {
					method99(aBoolean1266, (byte) 8, -1200);
					aBoolean1266 = true;
				}
				if (i_806_ == 4) {
					aBoolean1266 = false;
				}
				if (aBoolean1266 != bool && !Client.aBoolean926) {
					if (aBoolean1266) {
						anInt1270 = anInt1327;
						aBoolean1271 = true;
						aClass32_Sub1_1291.method329(2, anInt1270);
					} else {
						method50(false);
					}
					anInt1128 = 0;
				}
			}
			if (i_805_ == 4) {
				if (i_806_ == 0) {
					aBoolean1301 = true;
					method58(822, 0);
				}
				if (i_806_ == 1) {
					aBoolean1301 = true;
					method58(822, -400);
				}
				if (i_806_ == 2) {
					aBoolean1301 = true;
					method58(822, -800);
				}
				if (i_806_ == 3) {
					aBoolean1301 = true;
					method58(822, -1200);
				}
				if (i_806_ == 4) {
					aBoolean1301 = false;
				}
			}
			if (i_805_ == 5) {
				anInt1300 = i_806_;
			}
			if (i_805_ == 6) {
				anInt998 = i_806_;
			}
			if (i_805_ == 8) {
				anInt1223 = i_806_;
				aBoolean1240 = true;
			}
			if (i_805_ == 9) {
				anInt955 = i_806_;
			}
		}
	}

	public final int method106(int i, int i_807_, int i_808_, int i_809_) {
		if (i_809_ < 8 || i_809_ > 8) {
			aPacket_964.putByte(235);
		}
		int i_810_ = 256 - i_808_;
		return ((((i & 0xff00ff) * i_810_ + (i_807_ & 0xff00ff) * i_808_ & ~0xff00ff) + ((i & 0xff00)
			* i_810_ + (i_807_ & 0xff00) * i_808_ & 0xff0000)) >> 8);
	}

	public final void method107(int i) {
		anInt1246 = 0;
		int i_811_ = (((((ObjectInstance) Client.myPlayer).anInt1610) >> 7) + anInt1040);
		int i_812_ = (((((ObjectInstance) Client.myPlayer).anInt1611) >> 7) + anInt1041);
		if (i < 0) {
			if (i_811_ >= 3053 && i_811_ <= 3156 && i_812_ >= 3056 && i_812_ <= 3136) {
				anInt1246 = 1;
			}
			if (i_811_ >= 3072 && i_811_ <= 3118 && i_812_ >= 9492 && i_812_ <= 9535) {
				anInt1246 = 1;
			}
			if (anInt1246 == 1 && i_811_ >= 3139 && i_811_ <= 3199 && i_812_ >= 3008
				&& i_812_ <= 3062) {
				anInt1246 = 0;
			}
		}
	}

	public final void method108(int i) {
		int i_813_ = aFont_1061.method483((byte) 35, "Choose Option");
		for (int i_814_ = 0; i_814_ < anInt1183; i_814_++) {
			int i_815_ = aFont_1061.method483((byte) 35, aStringArray1184[i_814_]);
			if (i_815_ > i_813_) {
				i_813_ = i_815_;
			}
		}
		i_813_ += 8;
		if (i <= 0) {
			Client.aBoolean1190 = !Client.aBoolean1190;
		}
		int i_816_ = anInt1183 * 15 + 21;
		if (anInt29 > 4 && anInt30 > 4 && anInt29 < 516 && anInt30 < 338) {
			int i_817_ = anInt29 - 4 - i_813_ / 2;
			if (i_817_ + i_813_ > 512) {
				i_817_ = 512 - i_813_;
			}
			if (i_817_ < 0) {
				i_817_ = 0;
			}
			int i_818_ = anInt30 - 4;
			if (i_818_ + i_816_ > 334) {
				i_818_ = 334 - i_816_;
			}
			if (i_818_ < 0) {
				i_818_ = 0;
			}
			aBoolean1065 = true;
			anInt1304 = 0;
			anInt1305 = i_817_;
			anInt1306 = i_818_;
			anInt1307 = i_813_;
			anInt1308 = anInt1183 * 15 + 22;
		}
		if (anInt29 > 553 && anInt30 > 205 && anInt29 < 743 && anInt30 < 466) {
			int i_819_ = anInt29 - 553 - i_813_ / 2;
			if (i_819_ < 0) {
				i_819_ = 0;
			} else if (i_819_ + i_813_ > 190) {
				i_819_ = 190 - i_813_;
			}
			int i_820_ = anInt30 - 205;
			if (i_820_ < 0) {
				i_820_ = 0;
			} else if (i_820_ + i_816_ > 261) {
				i_820_ = 261 - i_816_;
			}
			aBoolean1065 = true;
			anInt1304 = 1;
			anInt1305 = i_819_;
			anInt1306 = i_820_;
			anInt1307 = i_813_;
			anInt1308 = anInt1183 * 15 + 22;
		}
		if (anInt29 > 17 && anInt30 > 357 && anInt29 < 496 && anInt30 < 453) {
			int i_821_ = anInt29 - 17 - i_813_ / 2;
			if (i_821_ < 0) {
				i_821_ = 0;
			} else if (i_821_ + i_813_ > 479) {
				i_821_ = 479 - i_813_;
			}
			int i_822_ = anInt30 - 357;
			if (i_822_ < 0) {
				i_822_ = 0;
			} else if (i_822_ + i_816_ > 96) {
				i_822_ = 96 - i_816_;
			}
			aBoolean1065 = true;
			anInt1304 = 2;
			anInt1305 = i_821_;
			anInt1306 = i_822_;
			anInt1307 = i_813_;
			anInt1308 = anInt1183 * 15 + 22;
		}
	}

	public final void method109(int i) {
		if (i != 30729) {
			anInt1056 = cryption.getNextKey();
		}
		method75(0);
		if (anInt1023 == 1) {
			aSpriteArray896[anInt1022 / 100].drawSprite(anInt1020 - 8 - 4, anInt1021 - 8 - 4);
		}
		if (anInt1023 == 2) {
			aSpriteArray896[anInt1022 / 100 + 4].drawSprite(anInt1020 - 8 - 4, anInt1021 - 8 - 4);
		}
		if (anInt1279 != -1) {
			method88(anInt951, anInt1279, (byte) 5);
			method142(0, 0, Interface.method195(anInt1279), 0, 8);
		}
		if (anInt1169 != -1) {
			method88(anInt951, anInt1169, (byte) 5);
			method142(0, 0, Interface.method195(anInt1169), 0, 8);
		}
		method107(-7);
		if (!aBoolean1065) {
			method91(-521);
			method34((byte) -79);
		} else if (anInt1304 == 0) {
			method128(false);
		}
		if (anInt1319 == 1) {
			overlay_multiway.drawSprite(472, 296);
		}
		if (Client.aBoolean868) {
			int i_823_ = 507;
			int i_824_ = 20;
			int i_825_ = 16776960;
			if (anInt10 < 30 && Client.aBoolean926) {
				i_825_ = 16711680;
			}
			if (anInt10 < 20 && !Client.aBoolean926) {
				i_825_ = 16711680;
			}
			aFont_1060.method480(true, "Fps:" + anInt10, i_825_, i_823_, i_824_);
			i_824_ += 15;
			Runtime runtime = Runtime.getRuntime();
			int i_826_ = (int) ((runtime.totalMemory() - runtime.freeMemory()) / 1024L);
			i_825_ = 16776960;
			if (i_826_ > 33554432 && Client.aBoolean926) {
				i_825_ = 16711680;
			}
			if (i_826_ > 67108864 && !Client.aBoolean926) {
				i_825_ = 16711680;
			}
			aFont_1060.method480(true, "Mem:" + i_826_ + "k", 16776960, i_823_, i_824_);
			i_824_ += 15;
		}
		if (anInt1057 != 0) {
			int i_827_ = anInt1057 / 50;
			int i_828_ = i_827_ / 60;
			i_827_ %= 60;
			if (i_827_ < 10) {
				aFont_1060.method485(2245, 4, 16776960, 329,
					("System update in: " + i_828_ + ":0" + i_827_));
			} else {
				aFont_1060.method485(2245, 4, 16776960, 329,
					("System update in: " + i_828_ + ":" + i_827_));
			}
			Client.anInt895++;
			if (Client.anInt895 > 112) {
				Client.anInt895 = 0;
				aPacket_964.putOpcode(197);
				aPacket_964.putInt(0);
			}
		}
	}

	public final void run() {
		if (aBoolean1314) {
			method17();
		} else {
			super.run();
		}
	}

	public final int method110(int i, int i_829_, byte i_830_, int i_831_) {
		int i_832_ = i_829_ >> 7;
		int i_833_ = i >> 7;
		if (i_832_ < 0 || i_833_ < 0 || i_832_ > 103 || i_833_ > 103) {
			return 0;
		}
		int i_834_ = i_831_;
		if (i_834_ < 3 && (aByteArrayArrayArray1125[1][i_832_][i_833_] & 0x2) == 2) {
			i_834_++;
		}
		int i_835_ = i_829_ & 0x7f;
		int i_836_ = i & 0x7f;
		if (i_830_ != 9) {
			aBoolean953 = !aBoolean953;
		}
		int i_837_ = ((anIntArrayArrayArray891[i_834_][i_832_][i_833_] * (128 - i_835_) + anIntArrayArrayArray891[i_834_][i_832_ + 1][i_833_]
			* i_835_) >> 7);
		int i_838_ = (anIntArrayArrayArray891[i_834_][i_832_][i_833_ + 1] * (128 - i_835_) + (anIntArrayArrayArray891[i_834_][i_832_ + 1][i_833_ + 1] * i_835_)) >> 7;
		return i_837_ * (128 - i_836_) + i_838_ * i_836_ >> 7;
	}

	public final AppletContext getAppletContext() {
		if (Signlink.mainapp != null) {
			return Signlink.mainapp.getAppletContext();
		}
		return super.getAppletContext();
	}

	public final void method111(int i) {
		i = 21 / i;
		if (anInt1223 != 0) {
			int i_839_ = 0;
			if (anInt1057 != 0) {
				i_839_ = 1;
			}
			for (int i_840_ = 0; i_840_ < 100; i_840_++) {
				if (aStringArray1298[i_840_] != null) {
					int i_841_ = anIntArray1296[i_840_];
					String string = aStringArray1297[i_840_];
					boolean bool = false;
					if (string != null && string.startsWith("@cr1@")) {
						string = string.substring(5);
						bool = true;
					}
					if (string != null && string.startsWith("@cr2@")) {
						string = string.substring(5);
						int i_842_ = 2;
					}
					if ((i_841_ == 3 || i_841_ == 7)
						&& (i_841_ == 7 || anInt887 == 0 || anInt887 == 1
							&& method148(13292, string))) {
						int i_843_ = 329 - i_839_ * 13;
						if (anInt22 > 4 && anInt23 - 4 > i_843_ - 10 && anInt23 - 4 <= i_843_ + 3) {
							int i_844_ = ((aFont_1060.method483((byte) 35,
								("From:  " + string + aStringArray1298[i_840_]))) + 25);
							if (i_844_ > 450) {
								i_844_ = 450;
							}
							if (anInt22 < i_844_ + 4) {
								if (anInt867 >= 1) {
									aStringArray1184[anInt1183] = "Report abuse @whi@" + string;
									anIntArray981[anInt1183] = 2507;
									anInt1183++;
								}
								aStringArray1184[anInt1183] = "Add ignore @whi@" + string;
								anIntArray981[anInt1183] = 2574;
								anInt1183++;
								aStringArray1184[anInt1183] = "Add friend @whi@" + string;
								anIntArray981[anInt1183] = 2762;
								anInt1183++;
							}
						}
						if (++i_839_ >= 5) {
							break;
						}
					}
					if ((i_841_ == 5 || i_841_ == 6) && anInt887 < 2 && ++i_839_ >= 5) {
						break;
					}
				}
			}
		}
	}

	public final void method112(byte i, int i_845_) {
		if (i != 36) {
			aPacket_964.putByte(6);
		}
		Interface iComponent = Interface.method195(i_845_);
		for (int element : iComponent.anIntArray258) {
			if (element == -1) {
				break;
			}
			Interface iComponent_847_ = Interface.method195(element);
			if (iComponent_847_.anInt236 == 1) {
				method112((byte) 36, iComponent_847_.anInt215);
			}
			iComponent_847_.anInt235 = 0;
			iComponent_847_.anInt227 = 0;
		}
	}

	public final void method113(int i, int i_848_, int i_849_) {
		int i_850_ = 0;
		i = 44 / i;
		for (int i_851_ = 0; i_851_ < 100; i_851_++) {
			if (aStringArray1298[i_851_] != null) {
				int i_852_ = anIntArray1296[i_851_];
				int i_853_ = 70 - i_850_ * 14 + anInt851 + 4;
				if (i_853_ < -20) {
					break;
				}
				String string = aStringArray1297[i_851_];
				boolean bool = false;
				if (string != null && string.startsWith("@cr1@")) {
					string = string.substring(5);
					bool = true;
				}
				if (string != null && string.startsWith("@cr2@")) {
					string = string.substring(5);
					int i_854_ = 2;
				}
				if (i_852_ == 0) {
					i_850_++;
				}
				if ((i_852_ == 1 || i_852_ == 2)
					&& (i_852_ == 1 || anInt1006 == 0 || anInt1006 == 1 && method148(13292, string))) {
					if (i_849_ > i_853_ - 14 && i_849_ <= i_853_
						&& !string.equals(((Player) Client.myPlayer).aString1751)) {
						if (anInt867 >= 1) {
							aStringArray1184[anInt1183] = "Report abuse @whi@" + string;
							anIntArray981[anInt1183] = 507;
							anInt1183++;
						}
						aStringArray1184[anInt1183] = "Add ignore @whi@" + string;
						anIntArray981[anInt1183] = 574;
						anInt1183++;
						aStringArray1184[anInt1183] = "Add friend @whi@" + string;
						anIntArray981[anInt1183] = 762;
						anInt1183++;
					}
					i_850_++;
				}
				if ((i_852_ == 3 || i_852_ == 7) && anInt1223 == 0
					&& (i_852_ == 7 || anInt887 == 0 || anInt887 == 1 && method148(13292, string))) {
					if (i_849_ > i_853_ - 14 && i_849_ <= i_853_) {
						if (anInt867 >= 1) {
							aStringArray1184[anInt1183] = "Report abuse @whi@" + string;
							anIntArray981[anInt1183] = 507;
							anInt1183++;
						}
						aStringArray1184[anInt1183] = "Add ignore @whi@" + string;
						anIntArray981[anInt1183] = 574;
						anInt1183++;
						aStringArray1184[anInt1183] = "Add friend @whi@" + string;
						anIntArray981[anInt1183] = 762;
						anInt1183++;
					}
					i_850_++;
				}
				if (i_852_ == 4 && (anInt1227 == 0 || anInt1227 == 1 && method148(13292, string))) {
					if (i_849_ > i_853_ - 14 && i_849_ <= i_853_) {
						aStringArray1184[anInt1183] = "Accept trade @whi@" + string;
						anIntArray981[anInt1183] = 544;
						anInt1183++;
					}
					i_850_++;
				}
				if ((i_852_ == 5 || i_852_ == 6) && anInt1223 == 0 && anInt887 < 2) {
					i_850_++;
				}
				if (i_852_ == 8 && (anInt1227 == 0 || anInt1227 == 1 && method148(13292, string))) {
					if (i_849_ > i_853_ - 14 && i_849_ <= i_853_) {
						aStringArray1184[anInt1183] = "Accept challenge @whi@" + string;
						anIntArray981[anInt1183] = 695;
						anInt1183++;
					}
					i_850_++;
				}
			}
		}
	}

	private final void method114(int i, int i_855_, Packet packet) {
		int i_856_ = packet.readBits(8);
		if (i_856_ < playerCount) {
			for (int i_857_ = i_856_; i_857_ < playerCount; i_857_++) {
				((Client) this).anIntArray1295[anInt1294++] = ((Client) this).playerIndices[i_857_];
			}
		}
		if (i_856_ > playerCount) {
			Signlink.reporterror(aString1092 + " Too many players");
			throw new RuntimeException("eek");
		}
		playerCount = 0;
		if (i_855_ >= 0) {
			opcode = -1;
		}
		for (int i_858_ = 0; i_858_ < i_856_; i_858_++) {
			int i_859_ = ((Client) this).playerIndices[i_858_];
			Player player = totalPlayers[i_859_];
			int i_860_ = packet.readBits(1);
			if (i_860_ == 0) {
				((Client) this).playerIndices[playerCount++] = i_859_;
				((ObjectInstance) player).anInt1585 = Client.anInt1325;
			} else {
				int i_861_ = packet.readBits(2);
				if (i_861_ == 0) {
					((Client) this).playerIndices[playerCount++] = i_859_;
					((ObjectInstance) player).anInt1585 = Client.anInt1325;
					anIntArray974[anInt973++] = i_859_;
				} else if (i_861_ == 1) {
					((Client) this).playerIndices[playerCount++] = i_859_;
					((ObjectInstance) player).anInt1585 = Client.anInt1325;
					int i_862_ = packet.readBits(3);
					player.method577(false, i_862_, -808);
					int i_863_ = packet.readBits(1);
					if (i_863_ == 1) {
						anIntArray974[anInt973++] = i_859_;
					}
				} else if (i_861_ == 2) {
					((Client) this).playerIndices[playerCount++] = i_859_;
					((ObjectInstance) player).anInt1585 = Client.anInt1325;
					int i_864_ = packet.readBits(3);
					player.method577(true, i_864_, -808);
					int i_865_ = packet.readBits(3);
					player.method577(true, i_865_, -808);
					int i_866_ = packet.readBits(1);
					if (i_866_ == 1) {
						anIntArray974[anInt973++] = i_859_;
					}
				} else if (i_861_ == 3) {
					((Client) this).anIntArray1295[anInt1294++] = i_859_;
				}
			}
		}
	}

	public final void method115(int i, int i_867_) {
		int[] is = aSprite_1122.pixels;
		int i_868_ = is.length;
		for (int i_869_ = 0; i_869_ < i_868_; i_869_++) {
			is[i_869_] = 0;
		}
		for (int i_870_ = 1; i_870_ < 103; i_870_++) {
			int i_871_ = (103 - i_870_) * 512 * 4 + 24628;
			for (int i_872_ = 1; i_872_ < 103; i_872_++) {
				if ((aByteArrayArrayArray1125[i][i_872_][i_870_] & 0x18) == 0) {
					aClass22_1164.method276(is, i_871_, 512, i, i_872_, i_870_);
				}
				if (i < 3 && (aByteArrayArrayArray1125[i + 1][i_872_][i_870_] & 0x8) != 0) {
					aClass22_1164.method276(is, i_871_, 512, i + 1, i_872_, i_870_);
				}
				i_871_ += 4;
			}
		}
		int i_873_ = (((int) (Math.random() * 20.0) + 238 - 10 << 16)
			+ ((int) (Math.random() * 20.0) + 238 - 10 << 8) + ((int) (Math.random() * 20.0) + 238 - 10));
		if (i_867_ != 0) {
			opcode = inputStream.getUByte();
		}
		int i_874_ = (int) (Math.random() * 20.0) + 238 - 10 << 16;
		aSprite_1122.method467();
		for (int i_875_ = 1; i_875_ < 103; i_875_++) {
			for (int i_876_ = 1; i_876_ < 103; i_876_++) {
				if ((aByteArrayArrayArray1125[i][i_876_][i_875_] & 0x18) == 0) {
					method150(i_875_, i, i_876_, i_874_, 563, i_873_);
				}
				if (i < 3 && (aByteArrayArrayArray1125[i + 1][i_876_][i_875_] & 0x8) != 0) {
					method150(i_875_, i + 1, i_876_, i_874_, 563, i_873_);
				}
			}
		}
		if (aGraphicsBuffer_1158 != null) {
			aGraphicsBuffer_1158.method230(false);
			Renderer3D.anIntArray1538 = anIntArray1002;
		}
		Client.anInt1082++;
		if (Client.anInt1082 > 177) {
			Client.anInt1082 = 0;
			aPacket_964.putOpcode(173);
			aPacket_964.put24BitInt(2657152);
		}
		anInt1076 = 0;
		for (int i_877_ = 0; i_877_ < 104; i_877_++) {
			for (int i_878_ = 0; i_878_ < 104; i_878_++) {
				int i_879_ = aClass22_1164.method270(anInt1091, i_877_, i_878_);
				if (i_879_ != 0) {
					i_879_ = i_879_ >> 14 & 0x7fff;
					int i_880_ = ObjectDefinition.method434(i_879_).anInt806;
					if (i_880_ >= 0) {
						int i_881_ = i_877_;
						int i_882_ = i_878_;
						if (i_880_ != 22 && i_880_ != 29 && i_880_ != 34 && i_880_ != 36
							&& i_880_ != 46 && i_880_ != 47 && i_880_ != 48) {
							int i_883_ = 104;
							int i_884_ = 104;
							int[][] is_885_ = (aCollisionMapArray1260[anInt1091].anIntArrayArray757);
							for (int i_886_ = 0; i_886_ < 10; i_886_++) {
								int i_887_ = (int) (Math.random() * 4.0);
								if (i_887_ == 0 && i_881_ > 0 && i_881_ > i_877_ - 3
									&& (is_885_[i_881_ - 1][i_882_] & 0x1280108) == 0) {
									i_881_--;
								}
								if (i_887_ == 1 && i_881_ < i_883_ - 1 && i_881_ < i_877_ + 3
									&& (is_885_[i_881_ + 1][i_882_] & 0x1280180) == 0) {
									i_881_++;
								}
								if (i_887_ == 2 && i_882_ > 0 && i_882_ > i_878_ - 3
									&& (is_885_[i_881_][i_882_ - 1] & 0x1280102) == 0) {
									i_882_--;
								}
								if (i_887_ == 3 && i_882_ < i_884_ - 1 && i_882_ < i_878_ + 3
									&& (is_885_[i_881_][i_882_ + 1] & 0x1280120) == 0) {
									i_882_++;
								}
							}
						}
						aSpriteArray1278[anInt1076] = mapfunctions[i_880_];
						anIntArray1077[anInt1076] = i_881_;
						anIntArray1078[anInt1076] = i_882_;
						anInt1076++;
					}
				}
			}
		}
	}

	public final boolean method116(int i, int i_888_, byte[] is) {
		if (i < 3 || i > 3) {
			throw new NullPointerException();
		}
		if (is == null) {
			return true;
		}
		return Signlink.wavesave(is, i_888_);
	}

	public final int method117(byte i) {
		int i_889_ = 3;
		if (i == aByte956) {
			boolean bool = false;
		} else {
			method6();
		}
		if (anInt1219 < 310) {
			Client.anInt978++;
			if (Client.anInt978 > 1457) {
				Client.anInt978 = 0;
				aPacket_964.putOpcode(244);
				aPacket_964.putByte(0);
				int i_890_ = aPacket_964.offset;
				aPacket_964.putByte(219);
				aPacket_964.putShort(37745);
				aPacket_964.putByte(61);
				aPacket_964.putShort(43756);
				aPacket_964.putShort((int) (Math.random() * 65536.0));
				aPacket_964.putByte((int) (Math.random() * 256.0));
				aPacket_964.putShort(51171);
				if ((int) (Math.random() * 2.0) == 0) {
					aPacket_964.putShort(15808);
				}
				aPacket_964.putByte(97);
				aPacket_964.putByte((int) (Math.random() * 256.0));
				aPacket_964.putSizeByte(aPacket_964.offset - i_890_);
			}
			int i_891_ = anInt1216 >> 7;
			int i_892_ = anInt1218 >> 7;
			int i_893_ = (((ObjectInstance) Client.myPlayer).anInt1610) >> 7;
			int i_894_ = (((ObjectInstance) Client.myPlayer).anInt1611) >> 7;
			if ((aByteArrayArrayArray1125[anInt1091][i_891_][i_892_] & 0x4) != 0) {
				i_889_ = anInt1091;
			}
			int i_895_;
			if (i_893_ > i_891_) {
				i_895_ = i_893_ - i_891_;
			} else {
				i_895_ = i_891_ - i_893_;
			}
			int i_896_;
			if (i_894_ > i_892_) {
				i_896_ = i_894_ - i_892_;
			} else {
				i_896_ = i_892_ - i_894_;
			}
			if (i_895_ > i_896_) {
				int i_897_ = i_896_ * 65536 / i_895_;
				int i_898_ = 32768;
				while (i_891_ != i_893_) {
					if (i_891_ < i_893_) {
						i_891_++;
					} else if (i_891_ > i_893_) {
						i_891_--;
					}
					if ((aByteArrayArrayArray1125[anInt1091][i_891_][i_892_] & 0x4) != 0) {
						i_889_ = anInt1091;
					}
					i_898_ += i_897_;
					if (i_898_ >= 65536) {
						i_898_ -= 65536;
						if (i_892_ < i_894_) {
							i_892_++;
						} else if (i_892_ > i_894_) {
							i_892_--;
						}
						if (((aByteArrayArrayArray1125[anInt1091][i_891_][i_892_]) & 0x4) != 0) {
							i_889_ = anInt1091;
						}
					}
				}
			} else {
				int i_899_ = i_895_ * 65536 / i_896_;
				int i_900_ = 32768;
				while (i_892_ != i_894_) {
					if (i_892_ < i_894_) {
						i_892_++;
					} else if (i_892_ > i_894_) {
						i_892_--;
					}
					if ((aByteArrayArrayArray1125[anInt1091][i_891_][i_892_] & 0x4) != 0) {
						i_889_ = anInt1091;
					}
					i_900_ += i_899_;
					if (i_900_ >= 65536) {
						i_900_ -= 65536;
						if (i_891_ < i_893_) {
							i_891_++;
						} else if (i_891_ > i_893_) {
							i_891_--;
						}
						if (((aByteArrayArrayArray1125[anInt1091][i_891_][i_892_]) & 0x4) != 0) {
							i_889_ = anInt1091;
						}
					}
				}
			}
		}
		if (((aByteArrayArrayArray1125[anInt1091][(((ObjectInstance) Client.myPlayer).anInt1610) >> 7][(((ObjectInstance) Client.myPlayer).anInt1611) >> 7]) & 0x4) != 0) {
			i_889_ = anInt1091;
		}
		return i_889_;
	}

	public final int method118(int i) {
		int i_901_ = method110(anInt1218, anInt1216, (byte) 9, anInt1091);
		while (i >= 0) {
			opcode = inputStream.getUByte();
		}
		if (i_901_ - anInt1217 < 800
			&& ((aByteArrayArrayArray1125[anInt1091][anInt1216 >> 7][anInt1218 >> 7]) & 0x4) != 0) {
			return anInt1091;
		}
		return 3;
	}

	public final void method12(Runnable runnable, int i) {
		if (i > 10) {
			i = 10;
		}
		if (Signlink.mainapp != null) {
			Signlink.startthread(runnable, i);
		} else {
			super.method12(runnable, i);
		}
	}

	public final void method119(int i, boolean bool) {
		if ((((ObjectInstance) Client.myPlayer).anInt1610) >> 7 == anInt1120
			&& (((ObjectInstance) Client.myPlayer).anInt1611) >> 7 == anInt1121) {
			anInt1120 = 0;
		}
		int i_902_ = playerCount;
		if (bool) {
			i_902_ = 1;
		}
		for (int i_903_ = 0; i_903_ < i_902_; i_903_++) {
			Player player;
			int i_904_;
			if (bool) {
				player = Client.myPlayer;
				i_904_ = anInt969 << 14;
			} else {
				player = (totalPlayers[((Client) this).playerIndices[i_903_]]);
				i_904_ = ((Client) this).playerIndices[i_903_] << 14;
			}
			if (player != null && player.method576(0)) {
				((Player) player).aBoolean1763 = false;
				if ((Client.aBoolean926 && playerCount > 50 || playerCount > 200)
					&& !bool
					&& ((((ObjectInstance) player).anInt1588) == ((ObjectInstance) player).anInt1634)) {
					((Player) player).aBoolean1763 = true;
				}
				int i_905_ = ((((ObjectInstance) player).anInt1610) >> 7);
				int i_906_ = ((((ObjectInstance) player).anInt1611) >> 7);
				if (i_905_ >= 0 && i_905_ < 104 && i_906_ >= 0 && i_906_ < 104) {
					if ((((Player) player).aModel_1746) != null
						&& Client.anInt1325 >= ((Player) player).anInt1764
						&& Client.anInt1325 < (((Player) player).anInt1765)) {
						((Player) player).aBoolean1763 = false;
						((Player) player).anInt1750 = method110(
							(((ObjectInstance) player).anInt1611),
							(((ObjectInstance) player).anInt1610), (byte) 9, anInt1091);
						aClass22_1164.method253(((Player) player).anInt1750,
							((Player) player).anInt1769, 60, 7, player,
							((Player) player).anInt1768,
							((ObjectInstance) player).anInt1611,
							((Player) player).anInt1771,
							((ObjectInstance) player).anInt1610,
							((ObjectInstance) player).anInt1612,
							((Player) player).anInt1770, anInt1091, i_904_);
					} else {
						if ((((ObjectInstance) player).anInt1610 & 0x7f) == 64
							&& (((ObjectInstance) player).anInt1611 & 0x7f) == 64) {
							if (anIntArrayArray886[i_905_][i_906_] == anInt1138) {
								continue;
							}
							anIntArrayArray886[i_905_][i_906_] = anInt1138;
						}
						((Player) player).anInt1750 = method110(
							(((ObjectInstance) player).anInt1611),
							(((ObjectInstance) player).anInt1610), (byte) 9, anInt1091);
						aClass22_1164.method252(i_904_, player,
							((ObjectInstance) player).anInt1610,
							((Player) player).anInt1750,
							((ObjectInstance) player).aBoolean1592, 0, anInt1091, 60,
							((ObjectInstance) player).anInt1611,
							((ObjectInstance) player).anInt1612);
					}
				}
			}
		}
		if (i != 0) {
			/* empty */
		}
	}

	public final void method120(int i, int i_907_) {
		if (i >= 0) {
			int i_908_ = anIntArray979[i];
			int i_909_ = anIntArray980[i];
			int i_910_ = anIntArray981[i];
			int i_911_ = anIntArray982[i];
			if (i_907_ < anInt921 || i_907_ > anInt921) {
				opcode = inputStream.getUByte();
			}
			if (i_910_ >= 2000) {
				i_910_ -= 2000;
			}
			if (anInt1244 != 0 && i_910_ != 1016) {
				anInt1244 = 0;
				aBoolean1240 = true;
			}
			if (i_910_ == 200) {
				Player player = totalPlayers[i_911_];
				if (player != null) {
					method35(false, false, ((ObjectInstance) player).anIntArray1587[0],
						(((ObjectInstance) Client.myPlayer).anIntArray1587[0]), 1, 1,
						2, 0, ((ObjectInstance) player).anIntArray1586[0], 0, 0,
						(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
					anInt1020 = anInt29;
					anInt1021 = anInt30;
					anInt1023 = 2;
					anInt1022 = 0;
					aPacket_964.putOpcode(245);
					aPacket_964.putLEShortA(i_911_);
				}
			}
			if (i_910_ == 227) {
				Client.anInt1165++;
				if (Client.anInt1165 >= 62) {
					aPacket_964.putOpcode(165);
					aPacket_964.putByte(206);
					Client.anInt1165 = 0;
				}
				aPacket_964.putOpcode(228);
				aPacket_964.putLEShort_duplicate(i_908_);
				aPacket_964.putShortA(i_911_);
				aPacket_964.putShort(i_909_);
				anInt1329 = 0;
				anInt1330 = i_909_;
				anInt1331 = i_908_;
				anInt1332 = 2;
				if (Interface.method195(i_909_).anInt248 == anInt1169) {
					anInt1332 = 1;
				}
				if (Interface.method195(i_909_).anInt248 == anInt988) {
					anInt1332 = 3;
				}
			}
			if (i_910_ == 876) {
				Player player = totalPlayers[i_911_];
				if (player != null) {
					method35(false, false, ((ObjectInstance) player).anIntArray1587[0],
						(((ObjectInstance) Client.myPlayer).anIntArray1587[0]), 1, 1,
						2, 0, ((ObjectInstance) player).anIntArray1586[0], 0, 0,
						(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
					anInt1020 = anInt29;
					anInt1021 = anInt30;
					anInt1023 = 2;
					anInt1022 = 0;
					aPacket_964.putOpcode(45);
					aPacket_964.putShortA(i_911_);
				}
			}
			if (i_910_ == 921) {
				Npc npc = totalNpcs[i_911_];
				if (npc != null) {
					method35(false, false, ((ObjectInstance) npc).anIntArray1587[0],
						(((ObjectInstance) Client.myPlayer).anIntArray1587[0]), 1, 1,
						2, 0, ((ObjectInstance) npc).anIntArray1586[0], 0, 0,
						(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
					anInt1020 = anInt29;
					anInt1021 = anInt30;
					anInt1023 = 2;
					anInt1022 = 0;
					aPacket_964.putOpcode(67);
					aPacket_964.putShortA(i_911_);
				}
			}
			if (i_910_ == 961) {
				Client.anInt1139 += i_911_;
				if (Client.anInt1139 >= 115) {
					aPacket_964.putOpcode(126);
					aPacket_964.putByte(125);
					Client.anInt1139 = 0;
				}
				aPacket_964.putOpcode(203);
				aPacket_964.putShortA(i_909_);
				aPacket_964.putLEShort_duplicate(i_908_);
				aPacket_964.putLEShort_duplicate(i_911_);
				anInt1329 = 0;
				anInt1330 = i_909_;
				anInt1331 = i_908_;
				anInt1332 = 2;
				if (Interface.method195(i_909_).anInt248 == anInt1169) {
					anInt1332 = 1;
				}
				if (Interface.method195(i_909_).anInt248 == anInt988) {
					anInt1332 = 3;
				}
			}
			if (i_910_ == 467 && method80(i_909_, 0, i_908_, i_911_)) {
				aPacket_964.putOpcode(152);
				aPacket_964.putLEShort_duplicate(i_911_ >> 14 & 0x7fff);
				aPacket_964.putLEShort_duplicate(anInt1148);
				aPacket_964.putLEShort_duplicate(anInt1149);
				aPacket_964.putLEShort_duplicate(i_909_ + anInt1041);
				aPacket_964.putShort(anInt1147);
				aPacket_964.putLEShortA(i_908_ + anInt1040);
			}
			if (i_910_ == 9) {
				aPacket_964.putOpcode(3);
				aPacket_964.putShortA(i_911_);
				aPacket_964.putShort(i_909_);
				aPacket_964.putShort(i_908_);
				anInt1329 = 0;
				anInt1330 = i_909_;
				anInt1331 = i_908_;
				anInt1332 = 2;
				if (Interface.method195(i_909_).anInt248 == anInt1169) {
					anInt1332 = 1;
				}
				if (Interface.method195(i_909_).anInt248 == anInt988) {
					anInt1332 = 3;
				}
			}
			if (i_910_ == 553) {
				Npc npc = totalNpcs[i_911_];
				if (npc != null) {
					method35(false, false, ((ObjectInstance) npc).anIntArray1587[0],
						(((ObjectInstance) Client.myPlayer).anIntArray1587[0]), 1, 1,
						2, 0, ((ObjectInstance) npc).anIntArray1586[0], 0, 0,
						(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
					anInt1020 = anInt29;
					anInt1021 = anInt30;
					anInt1023 = 2;
					anInt1022 = 0;
					aPacket_964.putOpcode(42);
					aPacket_964.putLEShort_duplicate(i_911_);
				}
			}
			if (i_910_ == 677) {
				Player player = totalPlayers[i_911_];
				if (player != null) {
					method35(false, false, ((ObjectInstance) player).anIntArray1587[0],
						(((ObjectInstance) Client.myPlayer).anIntArray1587[0]), 1, 1,
						2, 0, ((ObjectInstance) player).anIntArray1586[0], 0, 0,
						(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
					anInt1020 = anInt29;
					anInt1021 = anInt30;
					anInt1023 = 2;
					anInt1022 = 0;
					aPacket_964.putOpcode(116);
					aPacket_964.putLEShort_duplicate(i_911_);
				}
			}
			if (i_910_ == 762 || i_910_ == 574 || i_910_ == 775 || i_910_ == 859) {
				String string = aStringArray1184[i];
				int i_912_ = string.indexOf("@whi@");
				if (i_912_ != -1) {
					long l = TextUtil.method299(string.substring(i_912_ + 5).trim());
					if (i_910_ == 762) {
						method102(l, -45229);
					}
					if (i_910_ == 574) {
						method90(anInt1154, l);
					}
					if (i_910_ == 775) {
						method53(l, 0);
					}
					if (i_910_ == 859) {
						method97(325, l);
					}
				}
			}
			if (i_910_ == 930) {
				boolean bool = method35(false, false, i_909_,
					(((ObjectInstance) Client.myPlayer).anIntArray1587[0]), 0, 0, 2, 0,
					i_908_, 0, 0,
					(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
				if (!bool) {
					bool = method35(false, false, i_909_,
						(((ObjectInstance) Client.myPlayer).anIntArray1587[0]), 1, 1,
						2, 0, i_908_, 0, 0,
						(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
				}
				anInt1020 = anInt29;
				anInt1021 = anInt30;
				anInt1023 = 2;
				anInt1022 = 0;
				aPacket_964.putOpcode(54);
				aPacket_964.putShortA(i_911_);
				aPacket_964.putLEShort_duplicate(i_909_ + anInt1041);
				aPacket_964.putShort(i_908_ + anInt1040);
			}
			if (i_910_ == 399) {
				aPacket_964.putOpcode(24);
				aPacket_964.putLEShort_duplicate(i_909_);
				aPacket_964.putLEShort_duplicate(i_911_);
				aPacket_964.putShortA(i_908_);
				anInt1329 = 0;
				anInt1330 = i_909_;
				anInt1331 = i_908_;
				anInt1332 = 2;
				if (Interface.method195(i_909_).anInt248 == anInt1169) {
					anInt1332 = 1;
				}
				if (Interface.method195(i_909_).anInt248 == anInt988) {
					anInt1332 = 3;
				}
			}
			if (i_910_ == 347) {
				Npc npc = totalNpcs[i_911_];
				if (npc != null) {
					method35(false, false, ((ObjectInstance) npc).anIntArray1587[0],
						(((ObjectInstance) Client.myPlayer).anIntArray1587[0]), 1, 1,
						2, 0, ((ObjectInstance) npc).anIntArray1586[0], 0, 0,
						(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
					anInt1020 = anInt29;
					anInt1021 = anInt30;
					anInt1023 = 2;
					anInt1022 = 0;
					aPacket_964.putOpcode(57);
					aPacket_964.putShort(i_911_);
					aPacket_964.putLEShort_duplicate(anInt1149);
					aPacket_964.putLEShortA(anInt1148);
					aPacket_964.putShort(anInt1147);
				}
			}
			if (i_910_ == 890) {
				aPacket_964.putOpcode(79);
				aPacket_964.putShort(i_909_);
				Interface iComponent = Interface.method195(i_909_);
				if (iComponent.anIntArrayArray234 != null
					&& iComponent.anIntArrayArray234[0][0] == 5) {
					int i_913_ = iComponent.anIntArrayArray234[0][1];
					anIntArray1039[i_913_] = 1 - anIntArray1039[i_913_];
					method105(0, i_913_);
					drawInventoryRequest = true;
				}
			}
			if (i_910_ == 493) {
				Player player = totalPlayers[i_911_];
				if (player != null) {
					method35(false, false, ((ObjectInstance) player).anIntArray1587[0],
						(((ObjectInstance) Client.myPlayer).anIntArray1587[0]), 1, 1,
						2, 0, ((ObjectInstance) player).anIntArray1586[0], 0, 0,
						(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
					anInt1020 = anInt29;
					anInt1021 = anInt30;
					anInt1023 = 2;
					anInt1022 = 0;
					aPacket_964.putOpcode(233);
					aPacket_964.putShortA(i_911_);
				}
			}
			if (i_910_ == 14) {
				if (!aBoolean1065) {
					aClass22_1164.method279(0, anInt29 - 4, anInt30 - 4);
				} else {
					aClass22_1164.method279(0, i_908_ - 4, i_909_ - 4);
				}
			}
			if (i_910_ == 903) {
				aPacket_964.putOpcode(1);
				aPacket_964.putShort(i_911_);
				aPacket_964.putLEShort_duplicate(anInt1147);
				aPacket_964.putLEShort_duplicate(anInt1149);
				aPacket_964.putLEShortA(anInt1148);
				aPacket_964.putShortA(i_908_);
				aPacket_964.putShortA(i_909_);
				anInt1329 = 0;
				anInt1330 = i_909_;
				anInt1331 = i_908_;
				anInt1332 = 2;
				if (Interface.method195(i_909_).anInt248 == anInt1169) {
					anInt1332 = 1;
				}
				if (Interface.method195(i_909_).anInt248 == anInt988) {
					anInt1332 = 3;
				}
			}
			if (i_910_ == 361) {
				aPacket_964.putOpcode(36);
				aPacket_964.putShort(anInt1172);
				aPacket_964.putShortA(i_909_);
				aPacket_964.putShortA(i_908_);
				aPacket_964.putShortA(i_911_);
				anInt1329 = 0;
				anInt1330 = i_909_;
				anInt1331 = i_908_;
				anInt1332 = 2;
				if (Interface.method195(i_909_).anInt248 == anInt1169) {
					anInt1332 = 1;
				}
				if (Interface.method195(i_909_).anInt248 == anInt988) {
					anInt1332 = 3;
				}
			}
			if (i_910_ == 118) {
				Npc npc = totalNpcs[i_911_];
				if (npc != null) {
					method35(false, false, ((ObjectInstance) npc).anIntArray1587[0],
						(((ObjectInstance) Client.myPlayer).anIntArray1587[0]), 1, 1,
						2, 0, ((ObjectInstance) npc).anIntArray1586[0], 0, 0,
						(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
					anInt1020 = anInt29;
					anInt1021 = anInt30;
					anInt1023 = 2;
					anInt1022 = 0;
					Client.anInt1235 += i_911_;
					if (Client.anInt1235 >= 143) {
						aPacket_964.putOpcode(157);
						aPacket_964.putInt(0);
						Client.anInt1235 = 0;
					}
					aPacket_964.putOpcode(13);
					aPacket_964.putLEShortA(i_911_);
				}
			}
			if (i_910_ == 376 && method80(i_909_, 0, i_908_, i_911_)) {
				aPacket_964.putOpcode(210);
				aPacket_964.putShort(anInt1172);
				aPacket_964.putLEShort_duplicate(i_911_ >> 14 & 0x7fff);
				aPacket_964.putShortA(i_908_ + anInt1040);
				aPacket_964.putLEShort_duplicate(i_909_ + anInt1041);
			}
			if (i_910_ == 432) {
				Npc npc = totalNpcs[i_911_];
				if (npc != null) {
					method35(false, false, ((ObjectInstance) npc).anIntArray1587[0],
						(((ObjectInstance) Client.myPlayer).anIntArray1587[0]), 1, 1,
						2, 0, ((ObjectInstance) npc).anIntArray1586[0], 0, 0,
						(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
					anInt1020 = anInt29;
					anInt1021 = anInt30;
					anInt1023 = 2;
					anInt1022 = 0;
					aPacket_964.putOpcode(8);
					aPacket_964.putLEShort_duplicate(i_911_);
				}
			}
			if (i_910_ == 639) {
				method15(false);
			}
			if (i_910_ == 918) {
				Player player = totalPlayers[i_911_];
				if (player != null) {
					method35(false, false, ((ObjectInstance) player).anIntArray1587[0],
						(((ObjectInstance) Client.myPlayer).anIntArray1587[0]), 1, 1,
						2, 0, ((ObjectInstance) player).anIntArray1586[0], 0, 0,
						(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
					anInt1020 = anInt29;
					anInt1021 = anInt30;
					anInt1023 = 2;
					anInt1022 = 0;
					aPacket_964.putOpcode(31);
					aPacket_964.putShort(i_911_);
					aPacket_964.putLEShort_duplicate(anInt1172);
				}
			}
			if (i_910_ == 67) {
				Npc npc = totalNpcs[i_911_];
				if (npc != null) {
					method35(false, false, ((ObjectInstance) npc).anIntArray1587[0],
						(((ObjectInstance) Client.myPlayer).anIntArray1587[0]), 1, 1,
						2, 0, ((ObjectInstance) npc).anIntArray1586[0], 0, 0,
						(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
					anInt1020 = anInt29;
					anInt1021 = anInt30;
					anInt1023 = 2;
					anInt1022 = 0;
					aPacket_964.putOpcode(104);
					aPacket_964.putShortA(anInt1172);
					aPacket_964.putLEShort_duplicate(i_911_);
				}
			}
			if (i_910_ == 68) {
				boolean bool = method35(false, false, i_909_,
					(((ObjectInstance) Client.myPlayer).anIntArray1587[0]), 0, 0, 2, 0,
					i_908_, 0, 0,
					(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
				if (!bool) {
					bool = method35(false, false, i_909_,
						(((ObjectInstance) Client.myPlayer).anIntArray1587[0]), 1, 1,
						2, 0, i_908_, 0, 0,
						(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
				}
				anInt1020 = anInt29;
				anInt1021 = anInt30;
				anInt1023 = 2;
				anInt1022 = 0;
				aPacket_964.putOpcode(77);
				aPacket_964.putShortA(i_908_ + anInt1040);
				aPacket_964.putShort(i_909_ + anInt1041);
				aPacket_964.putLEShortA(i_911_);
			}
			if (i_910_ == 684) {
				boolean bool = method35(false, false, i_909_,
					(((ObjectInstance) Client.myPlayer).anIntArray1587[0]), 0, 0, 2, 0,
					i_908_, 0, 0,
					(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
				if (!bool) {
					bool = method35(false, false, i_909_,
						(((ObjectInstance) Client.myPlayer).anIntArray1587[0]), 1, 1,
						2, 0, i_908_, 0, 0,
						(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
				}
				anInt1020 = anInt29;
				anInt1021 = anInt30;
				anInt1023 = 2;
				anInt1022 = 0;
				if ((i_911_ & 0x3) == 0) {
					Client.anInt1052++;
				}
				if (Client.anInt1052 >= 84) {
					aPacket_964.putOpcode(222);
					aPacket_964.put24BitInt(11257922);
					Client.anInt1052 = 0;
				}
				aPacket_964.putOpcode(71);
				aPacket_964.putLEShortA(i_911_);
				aPacket_964.putLEShortA(i_908_ + anInt1040);
				aPacket_964.putShortA(i_909_ + anInt1041);
			}
			if (i_910_ == 544 || i_910_ == 695) {
				String string = aStringArray1184[i];
				int i_914_ = string.indexOf("@whi@");
				if (i_914_ != -1) {
					string = string.substring(i_914_ + 5).trim();
					String string_915_ = (TextUtil.method303(TextUtil.method300(
						TextUtil.method299(string), 0)));
					boolean bool = false;
					for (int i_916_ = 0; i_916_ < playerCount; i_916_++) {
						Player player = (totalPlayers[((Client) this).playerIndices[i_916_]]);
						if (player != null && (((Player) player).aString1751 != null)
							&& ((Player) player).aString1751.equalsIgnoreCase(string_915_)) {
							method35(false, false,
								(((ObjectInstance) player).anIntArray1587[0]),
								(((ObjectInstance) Client.myPlayer).anIntArray1587[0]),
								1, 1, 2, 0, (((ObjectInstance) player).anIntArray1586[0]),
								0, 0,
								(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
							if (i_910_ == 544) {
								aPacket_964.putOpcode(116);
								aPacket_964
									.putLEShort_duplicate(((Client) this).playerIndices[i_916_]);
							}
							if (i_910_ == 695) {
								aPacket_964.putOpcode(245);
								aPacket_964.putLEShortA(((Client) this).playerIndices[i_916_]);
							}
							bool = true;
							break;
						}
					}
					if (!bool) {
						sendMessage("", "Unable to find " + string_915_, 0);
					}
				}
			}
			if (i_910_ == 225) {
				aPacket_964.putOpcode(177);
				aPacket_964.putShortA(i_908_);
				aPacket_964.putLEShort_duplicate(i_911_);
				aPacket_964.putLEShort_duplicate(i_909_);
				anInt1329 = 0;
				anInt1330 = i_909_;
				anInt1331 = i_908_;
				anInt1332 = 2;
				if (Interface.method195(i_909_).anInt248 == anInt1169) {
					anInt1332 = 1;
				}
				if (Interface.method195(i_909_).anInt248 == anInt988) {
					anInt1332 = 3;
				}
			}
			if (i_910_ == 70) {
				Interface iComponent = Interface.method195(i_909_);
				anInt1171 = 1;
				anInt1172 = i_909_;
				anInt1173 = iComponent.anInt222;
				anInt1146 = 0;
				drawInventoryRequest = true;
				String string = iComponent.aString281;
				if (string.indexOf(" ") != -1) {
					string = string.substring(0, string.indexOf(" "));
				}
				String string_917_ = iComponent.aString281;
				if (string_917_.indexOf(" ") != -1) {
					string_917_ = string_917_.substring(string_917_.indexOf(" ") + 1);
				}
				((Client) this).aString1174 = string + " " + iComponent.aString211 + " "
					+ string_917_;
				if (anInt1173 == 16) {
					drawInventoryRequest = true;
					anInt1285 = 3;
					aBoolean950 = true;
				}
			} else {
				if (i_910_ == 891) {
					aPacket_964.putOpcode(4);
					aPacket_964.putLEShort_duplicate(i_908_);
					aPacket_964.putLEShortA(i_911_);
					aPacket_964.putLEShortA(i_909_);
					anInt1329 = 0;
					anInt1330 = i_909_;
					anInt1331 = i_908_;
					anInt1332 = 2;
					if (Interface.method195(i_909_).anInt248 == anInt1169) {
						anInt1332 = 1;
					}
					if (Interface.method195(i_909_).anInt248 == anInt988) {
						anInt1332 = 3;
					}
				}
				if (i_910_ == 894) {
					aPacket_964.putOpcode(158);
					aPacket_964.putLEShortA(i_908_);
					aPacket_964.putLEShortA(i_911_);
					aPacket_964.putLEShort_duplicate(i_909_);
					anInt1329 = 0;
					anInt1330 = i_909_;
					anInt1331 = i_908_;
					anInt1332 = 2;
					if (Interface.method195(i_909_).anInt248 == anInt1169) {
						anInt1332 = 1;
					}
					if (Interface.method195(i_909_).anInt248 == anInt988) {
						anInt1332 = 3;
					}
				}
				if (i_910_ == 1280) {
					method80(i_909_, 0, i_908_, i_911_);
					aPacket_964.putOpcode(55);
					aPacket_964.putLEShort_duplicate(i_911_ >> 14 & 0x7fff);
					aPacket_964.putLEShort_duplicate(i_909_ + anInt1041);
					aPacket_964.putShort(i_908_ + anInt1040);
				}
				if (i_910_ == 35) {
					method80(i_909_, 0, i_908_, i_911_);
					aPacket_964.putOpcode(181);
					aPacket_964.putShortA(i_908_ + anInt1040);
					aPacket_964.putLEShort_duplicate(i_909_ + anInt1041);
					aPacket_964.putLEShort_duplicate(i_911_ >> 14 & 0x7fff);
				}
				if (i_910_ == 888) {
					method80(i_909_, 0, i_908_, i_911_);
					aPacket_964.putOpcode(50);
					aPacket_964.putShortA(i_909_ + anInt1041);
					aPacket_964.putLEShort_duplicate(i_911_ >> 14 & 0x7fff);
					aPacket_964.putLEShortA(i_908_ + anInt1040);
				}
				if (i_910_ == 324) {
					aPacket_964.putOpcode(161);
					aPacket_964.putLEShortA(i_908_);
					aPacket_964.putLEShortA(i_911_);
					aPacket_964.putLEShort_duplicate(i_909_);
					anInt1329 = 0;
					anInt1330 = i_909_;
					anInt1331 = i_908_;
					anInt1332 = 2;
					if (Interface.method195(i_909_).anInt248 == anInt1169) {
						anInt1332 = 1;
					}
					if (Interface.method195(i_909_).anInt248 == anInt988) {
						anInt1332 = 3;
					}
				}
				if (i_910_ == 1094) {
					ItemDefinition itemDefinition = ItemDefinition.method212(i_911_);
					Interface iComponent = Interface.method195(i_909_);
					String string;
					if (iComponent != null && iComponent.anIntArray224[i_908_] >= 100000) {
						string = (String.valueOf(iComponent.anIntArray224[i_908_]) + " x " + itemDefinition.examine);
					} else if (itemDefinition.aByteArray328 != null) {
						string = new String(itemDefinition.aByteArray328);
					} else {
						string = "It's a " + itemDefinition.examine + ".";
					}
					sendMessage("", string, 0);
				}
				if (i_910_ == 352) {
					Interface iComponent = Interface.method195(i_909_);
					boolean bool = true;
					if (iComponent.anInt242 > 0) {
						bool = method60(631, iComponent);
					}
					if (bool) {
						aPacket_964.putOpcode(79);
						aPacket_964.putShort(i_909_);
					}
				}
				if (i_910_ == 1412) {
					int i_918_ = i_911_ >> 14 & 0x7fff;
					ObjectDefinition objectDefinition = ObjectDefinition.method434(i_918_);
					String string;
					if (objectDefinition.aByteArray783 != null) {
						string = new String(objectDefinition.aByteArray783);
					} else {
						string = "It's a " + objectDefinition.aString776 + ".";
					}
					sendMessage("", string, 0);
				}
				if (i_910_ == 575 && !aBoolean1239) {
					aPacket_964.putOpcode(226);
					aPacket_964.putShort(i_909_);
					aBoolean1239 = true;
				}
				if (i_910_ == 892) {
					method80(i_909_, 0, i_908_, i_911_);
					aPacket_964.putOpcode(136);
					aPacket_964.putShort(i_908_ + anInt1040);
					aPacket_964.putLEShort_duplicate(i_909_ + anInt1041);
					aPacket_964.putShort(i_911_ >> 14 & 0x7fff);
				}
				if (i_910_ == 270) {
					boolean bool = method35(false, false, i_909_,
						(((ObjectInstance) Client.myPlayer).anIntArray1587[0]), 0, 0,
						2, 0, i_908_, 0, 0,
						(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
					if (!bool) {
						bool = method35(false, false, i_909_,
							(((ObjectInstance) Client.myPlayer).anIntArray1587[0]), 1,
							1, 2, 0, i_908_, 0, 0,
							(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
					}
					anInt1020 = anInt29;
					anInt1021 = anInt30;
					anInt1023 = 2;
					anInt1022 = 0;
					aPacket_964.putOpcode(230);
					aPacket_964.putLEShort_duplicate(i_911_);
					aPacket_964.putShortA(i_908_ + anInt1040);
					aPacket_964.putShort(i_909_ + anInt1041);
				}
				if (i_910_ == 596) {
					Player player = totalPlayers[i_911_];
					if (player != null) {
						method35(false, false,
							(((ObjectInstance) player).anIntArray1587[0]),
							(((ObjectInstance) Client.myPlayer).anIntArray1587[0]), 1,
							1, 2, 0, (((ObjectInstance) player).anIntArray1586[0]), 0, 0,
							(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
						anInt1020 = anInt29;
						anInt1021 = anInt30;
						anInt1023 = 2;
						anInt1022 = 0;
						aPacket_964.putOpcode(143);
						aPacket_964.putLEShort_duplicate(anInt1149);
						aPacket_964.putLEShortA(anInt1147);
						aPacket_964.putShort(anInt1148);
						aPacket_964.putShortA(i_911_);
					}
				}
				if (i_910_ == 100) {
					boolean bool = method35(false, false, i_909_,
						(((ObjectInstance) Client.myPlayer).anIntArray1587[0]), 0, 0,
						2, 0, i_908_, 0, 0,
						(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
					if (!bool) {
						bool = method35(false, false, i_909_,
							(((ObjectInstance) Client.myPlayer).anIntArray1587[0]), 1,
							1, 2, 0, i_908_, 0, 0,
							(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
					}
					anInt1020 = anInt29;
					anInt1021 = anInt30;
					anInt1023 = 2;
					anInt1022 = 0;
					aPacket_964.putOpcode(211);
					aPacket_964.putLEShortA(anInt1147);
					aPacket_964.putShortA(anInt1149);
					aPacket_964.putLEShortA(i_909_ + anInt1041);
					aPacket_964.putLEShortA(i_908_ + anInt1040);
					aPacket_964.putLEShort_duplicate(anInt1148);
					aPacket_964.putLEShort_duplicate(i_911_);
				}
				if (i_910_ == 1668) {
					Npc npc = totalNpcs[i_911_];
					if (npc != null) {
						NpcDefinition npcDefinition = (((Npc) npc).npc);
						if (npcDefinition.childIds != null) {
							npcDefinition = npcDefinition.method374();
						}
						if (npcDefinition != null) {
							String string;
							if (npcDefinition.aByteArray660 != null) {
								string = new String(npcDefinition.aByteArray660);
							} else {
								string = "It's a " + npcDefinition.examine + ".";
							}
							sendMessage("", string, 0);
						}
					}
				}
				if (i_910_ == 26) {
					boolean bool = method35(false, false, i_909_,
						(((ObjectInstance) Client.myPlayer).anIntArray1587[0]), 0, 0,
						2, 0, i_908_, 0, 0,
						(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
					if (!bool) {
						bool = method35(false, false, i_909_,
							(((ObjectInstance) Client.myPlayer).anIntArray1587[0]), 1,
							1, 2, 0, i_908_, 0, 0,
							(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
					}
					anInt1020 = anInt29;
					anInt1021 = anInt30;
					anInt1023 = 2;
					anInt1022 = 0;
					Client.anInt1100++;
					if (Client.anInt1100 >= 120) {
						aPacket_964.putOpcode(95);
						aPacket_964.putInt(0);
						Client.anInt1100 = 0;
					}
					aPacket_964.putOpcode(100);
					aPacket_964.putShort(i_908_ + anInt1040);
					aPacket_964.putShortA(i_909_ + anInt1041);
					aPacket_964.putLEShortA(i_911_);
				}
				if (i_910_ == 444) {
					aPacket_964.putOpcode(91);
					aPacket_964.putLEShort_duplicate(i_911_);
					aPacket_964.putLEShortA(i_908_);
					aPacket_964.putShort(i_909_);
					anInt1329 = 0;
					anInt1330 = i_909_;
					anInt1331 = i_908_;
					anInt1332 = 2;
					if (Interface.method195(i_909_).anInt248 == anInt1169) {
						anInt1332 = 1;
					}
					if (Interface.method195(i_909_).anInt248 == anInt988) {
						anInt1332 = 3;
					}
				}
				if (i_910_ == 507) {
					String string = aStringArray1184[i];
					int i_919_ = string.indexOf("@whi@");
					if (i_919_ != -1) {
						if (anInt1169 == -1) {
							method15(false);
							aString839 = string.substring(i_919_ + 5).trim();
							aBoolean1098 = false;
							anInt1231 = anInt1169 = Interface.anInt246;
						} else {
							sendMessage(
								"",
								"Please close the interface you have open before using 'report abuse'",
								0);
						}
					}
				}
				if (i_910_ == 389) {
					method80(i_909_, 0, i_908_, i_911_);
					aPacket_964.putOpcode(241);
					aPacket_964.putShort(i_911_ >> 14 & 0x7fff);
					aPacket_964.putShort(i_908_ + anInt1040);
					aPacket_964.putShortA(i_909_ + anInt1041);
				}
				if (i_910_ == 564) {
					aPacket_964.putOpcode(231);
					aPacket_964.putLEShortA(i_909_);
					aPacket_964.putLEShort_duplicate(i_908_);
					aPacket_964.putShort(i_911_);
					anInt1329 = 0;
					anInt1330 = i_909_;
					anInt1331 = i_908_;
					anInt1332 = 2;
					if (Interface.method195(i_909_).anInt248 == anInt1169) {
						anInt1332 = 1;
					}
					if (Interface.method195(i_909_).anInt248 == anInt988) {
						anInt1332 = 3;
					}
				}
				if (i_910_ == 984) {
					String string = aStringArray1184[i];
					int i_920_ = string.indexOf("@whi@");
					if (i_920_ != -1) {
						long l = TextUtil.method299(string.substring(i_920_ + 5).trim());
						int i_921_ = -1;
						for (int i_922_ = 0; i_922_ < friendCount; i_922_++) {
							if (friendNameForLong[i_922_] == l) {
								i_921_ = i_922_;
								break;
							}
						}
						if (i_921_ != -1 && friendNodeIds[i_921_] > 0) {
							aBoolean1240 = true;
							anInt1244 = 0;
							aBoolean866 = true;
							aString1026 = "";
							anInt1221 = 3;
							aLong1141 = friendNameForLong[i_921_];
							aString937 = ("Enter message to send to " + friendNames[i_921_]);
						}
					}
				}
				if (i_910_ == 518) {
					aPacket_964.putOpcode(79);
					aPacket_964.putShort(i_909_);
					Interface iComponent = Interface.method195(i_909_);
					if (iComponent.anIntArrayArray234 != null
						&& iComponent.anIntArrayArray234[0][0] == 5) {
						int i_923_ = iComponent.anIntArrayArray234[0][1];
						if (anIntArray1039[i_923_] != iComponent.anIntArray256[0]) {
							anIntArray1039[i_923_] = iComponent.anIntArray256[0];
							method105(0, i_923_);
							drawInventoryRequest = true;
						}
					}
				}
				if (i_910_ == 318) {
					Npc npc = totalNpcs[i_911_];
					if (npc != null) {
						method35(false, false, (((ObjectInstance) npc).anIntArray1587[0]),
							(((ObjectInstance) Client.myPlayer).anIntArray1587[0]), 1,
							1, 2, 0, (((ObjectInstance) npc).anIntArray1586[0]), 0, 0,
							(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
						anInt1020 = anInt29;
						anInt1021 = anInt30;
						anInt1023 = 2;
						anInt1022 = 0;
						aPacket_964.putOpcode(112);
						aPacket_964.putLEShort_duplicate(i_911_);
					}
				}
				if (i_910_ == 199) {
					boolean bool = method35(false, false, i_909_,
						(((ObjectInstance) Client.myPlayer).anIntArray1587[0]), 0, 0,
						2, 0, i_908_, 0, 0,
						(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
					if (!bool) {
						bool = method35(false, false, i_909_,
							(((ObjectInstance) Client.myPlayer).anIntArray1587[0]), 1,
							1, 2, 0, i_908_, 0, 0,
							(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
					}
					anInt1020 = anInt29;
					anInt1021 = anInt30;
					anInt1023 = 2;
					anInt1022 = 0;
					aPacket_964.putOpcode(83);
					aPacket_964.putLEShort_duplicate(i_911_);
					aPacket_964.putShort(i_909_ + anInt1041);
					aPacket_964.putLEShort_duplicate(anInt1172);
					aPacket_964.putLEShortA(i_908_ + anInt1040);
				}
				if (i_910_ == 55) {
					method44(Client.aBoolean1190, anInt1191);
					anInt1191 = -1;
					aBoolean1240 = true;
				}
				if (i_910_ == 52) {
					anInt1146 = 1;
					anInt1147 = i_908_;
					anInt1148 = i_909_;
					anInt1149 = i_911_;
					((Client) this).aString1150 = ItemDefinition.method212(i_911_).examine;
					anInt1171 = 0;
					drawInventoryRequest = true;
				} else {
					if (i_910_ == 1564) {
						ItemDefinition itemDefinition = ItemDefinition.method212(i_911_);
						String string;
						if (itemDefinition.aByteArray328 != null) {
							string = new String(itemDefinition.aByteArray328);
						} else {
							string = "It's a " + itemDefinition.examine + ".";
						}
						sendMessage("", string, 0);
					}
					if (i_910_ == 408) {
						Player player = totalPlayers[i_911_];
						if (player != null) {
							method35(false, false,
								(((ObjectInstance) player).anIntArray1587[0]),
								(((ObjectInstance) Client.myPlayer).anIntArray1587[0]),
								1, 1, 2, 0, (((ObjectInstance) player).anIntArray1586[0]),
								0, 0,
								(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
							anInt1020 = anInt29;
							anInt1021 = anInt30;
							anInt1023 = 2;
							anInt1022 = 0;
							aPacket_964.putOpcode(194);
							aPacket_964.putLEShort_duplicate(i_911_);
						}
					}
					anInt1146 = 0;
					anInt1171 = 0;
					drawInventoryRequest = true;
				}
			}
		}
	}

	public final void updateEntites() {
		anInt939 = 0;
		for (int entityId = -1; entityId < playerCount + npcCount; entityId++) {
			ObjectInstance objectInstance;
			if (entityId == -1) {
				objectInstance = Client.myPlayer;
			} else if (entityId < playerCount) {
				objectInstance = (totalPlayers[((Client) this).playerIndices[entityId]]);
			} else {
				objectInstance = (totalNpcs[((Client) this).anIntArray1134[entityId - playerCount]]);
			}
			if (objectInstance != null && objectInstance.method576(0)) {
				if (objectInstance instanceof Npc) {
					NpcDefinition npcDefinition = (((Npc) (Npc) objectInstance).npc);
					if (npcDefinition.childIds != null) {
						npcDefinition = npcDefinition.method374();
					}
					if (npcDefinition == null) {
						continue;
					}
				}
				if (entityId < playerCount) {
					int drawY = 30;
					Player player = (Player) objectInstance;
					if (((Player) player).skullIcon != -1 || ((Player) player).prayerIcon != -1) {
						worldToScreen(objectInstance, ((ObjectInstance) objectInstance).height + 15);
						if (spriteDrawX > -1) {
							if (((Player) player).skullIcon != -1) {
								headicons_pk[((Player) player).skullIcon].drawSprite(spriteDrawX - 12, spriteDrawY
										- drawY);
								drawY += 25;
							}
							if (((Player) player).prayerIcon != -1) {
								headicons_prayer[((Player) player).prayerIcon].drawSprite(spriteDrawX - 12, spriteDrawY
										- drawY);
								drawY += 25;
							}
						}
					}
					if (entityId >= 0 && anInt1197 == 10 && anInt1151 == ((Client) this).playerIndices[entityId]) {
						worldToScreen(objectInstance, ((ObjectInstance) objectInstance).height + 15);
						if (spriteDrawX > -1) {
							headicons_hint[1].drawSprite(spriteDrawX - 12, spriteDrawY - drawY);
						}
					}
				} else {
					NpcDefinition npcDefinition = (((Npc) (Npc) objectInstance).npc);
					if (npcDefinition.anInt638 >= 0
						&& (npcDefinition.anInt638 < headicons_prayer.length)) {
						worldToScreen(objectInstance, ((ObjectInstance) objectInstance).height + 15);
						if (spriteDrawX > -1) {
							headicons_prayer[npcDefinition.anInt638].drawSprite(spriteDrawX - 12,
								spriteDrawY - 30);
						}
					}
					if (anInt1197 == 1
						&& (anInt1226 == ((Client) this).anIntArray1134[entityId - playerCount])
						&& Client.anInt1325 % 20 < 10) {
						worldToScreen(objectInstance, ((ObjectInstance) objectInstance).height + 15);
						if (spriteDrawX > -1) {
							headicons_hint[0].drawSprite(spriteDrawX - 12, spriteDrawY - 28);
						}
					}
				}
				if ((((ObjectInstance) objectInstance).aString1580) != null
					&& (entityId >= playerCount || anInt1006 == 0 || anInt1006 == 3 || (anInt1006 == 1 && method148(
						13292, (((Player) (Player) objectInstance).aString1751))))) {
					worldToScreen(objectInstance, ((ObjectInstance) objectInstance).height);
					if (spriteDrawX > -1 && anInt939 < anInt940) {
						anIntArray944[anInt939] = (aFont_1061.method484(
							((ObjectInstance) objectInstance).aString1580,
							(byte) -53)) / 2;
						anIntArray943[anInt939] = aFont_1061.anInt1506;
						anIntArray941[anInt939] = spriteDrawX;
						anIntArray942[anInt939] = spriteDrawY;
						anIntArray945[anInt939] = ((ObjectInstance) objectInstance).anInt1583;
						anIntArray946[anInt939] = ((ObjectInstance) objectInstance).anInt1593;
						anIntArray947[anInt939] = ((ObjectInstance) objectInstance).anInt1582;
						aStringArray948[anInt939++] = ((ObjectInstance) objectInstance).aString1580;
						if (anInt998 == 0
							&& ((ObjectInstance) objectInstance).anInt1593 >= 1
							&& ((ObjectInstance) objectInstance).anInt1593 <= 3) {
							anIntArray943[anInt939] += 10;
							anIntArray942[anInt939] += 5;
						}
						if (anInt998 == 0
							&& ((ObjectInstance) objectInstance).anInt1593 == 4) {
							anIntArray944[anInt939] = 60;
						}
						if (anInt998 == 0
							&& ((ObjectInstance) objectInstance).anInt1593 == 5) {
							anIntArray943[anInt939] += 5;
						}
					}
				}
				if (((ObjectInstance) objectInstance).anInt1595 > Client.anInt1325) {
					worldToScreen(objectInstance, ((ObjectInstance) objectInstance).height + 15);
					if (spriteDrawX > -1) {
						int i_925_ = (((ObjectInstance) objectInstance).anInt1596 * 30 / ((ObjectInstance) objectInstance).anInt1597);
						if (i_925_ > 30) {
							i_925_ = 30;
						}
						Renderer2D.method460(5, spriteDrawY - 3, 65280, (byte) -24, i_925_,
							spriteDrawX - 15);
						Renderer2D.method460(5, spriteDrawY - 3, 16711680, (byte) -24, 30 - i_925_,
							spriteDrawX - 15 + i_925_);
					}
				}
				for (int i_926_ = 0; i_926_ < 4; i_926_++) {
					if ((((ObjectInstance) objectInstance).anIntArray1632[i_926_]) > Client.anInt1325) {
						worldToScreen(objectInstance, ((ObjectInstance) objectInstance).height / 2);
						if (spriteDrawX > -1) {
							if (i_926_ == 1) {
								spriteDrawY -= 20;
							}
							if (i_926_ == 2) {
								spriteDrawX -= 15;
								spriteDrawY -= 10;
							}
							if (i_926_ == 3) {
								spriteDrawX += 15;
								spriteDrawY -= 10;
							}
							hitmarks[(((ObjectInstance) objectInstance).anIntArray1631[i_926_])]
								.drawSprite(spriteDrawX - 12, spriteDrawY - 12);
							aFont_1059
								.method481(
									spriteDrawX,
									452,
									spriteDrawY + 4,
									0,
									String
										.valueOf(((ObjectInstance) objectInstance).anIntArray1630[i_926_]));
							aFont_1059
								.method481(
									spriteDrawX - 1,
									452,
									spriteDrawY + 3,
									16777215,
									String
										.valueOf(((ObjectInstance) objectInstance).anIntArray1630[i_926_]));
						}
					}
				}
			}
		}
		for (int i = 0; i < anInt939; i++) {
			int i_927_ = anIntArray941[i];
			int i_928_ = anIntArray942[i];
			int i_929_ = anIntArray944[i];
			int i_930_ = anIntArray943[i];
			boolean bool_931_ = true;
			while (bool_931_) {
				bool_931_ = false;
				for (int i_932_ = 0; i_932_ < i; i_932_++) {
					if ((i_928_ + 2 > anIntArray942[i_932_] - anIntArray943[i_932_])
						&& i_928_ - i_930_ < anIntArray942[i_932_] + 2
						&& (i_927_ - i_929_ < anIntArray941[i_932_] + anIntArray944[i_932_])
						&& (i_927_ + i_929_ > anIntArray941[i_932_] - anIntArray944[i_932_])
						&& (anIntArray942[i_932_] - anIntArray943[i_932_] < i_928_)) {
						i_928_ = anIntArray942[i_932_] - anIntArray943[i_932_];
						bool_931_ = true;
					}
				}
			}
			spriteDrawX = anIntArray941[i];
			spriteDrawY = anIntArray942[i] = i_928_;
			String string = aStringArray948[i];
			if (anInt998 == 0) {
				int i_933_ = 16776960;
				if (anIntArray945[i] < 6) {
					i_933_ = anIntArray842[anIntArray945[i]];
				}
				if (anIntArray945[i] == 6) {
					i_933_ = anInt1138 % 20 < 10 ? 16711680 : 16776960;
				}
				if (anIntArray945[i] == 7) {
					i_933_ = anInt1138 % 20 < 10 ? 255 : 65535;
				}
				if (anIntArray945[i] == 8) {
					i_933_ = anInt1138 % 20 < 10 ? 45056 : 8454016;
				}
				if (anIntArray945[i] == 9) {
					int i_934_ = 150 - anIntArray947[i];
					if (i_934_ < 50) {
						i_933_ = 16711680 + i_934_ * 1280;
					} else if (i_934_ < 100) {
						i_933_ = 16776960 - (i_934_ - 50) * 327680;
					} else if (i_934_ < 150) {
						i_933_ = 65280 + (i_934_ - 100) * 5;
					}
				}
				if (anIntArray945[i] == 10) {
					int i_935_ = 150 - anIntArray947[i];
					if (i_935_ < 50) {
						i_933_ = 16711680 + i_935_ * 5;
					} else if (i_935_ < 100) {
						i_933_ = 16711935 - (i_935_ - 50) * 327680;
					} else if (i_935_ < 150) {
						i_933_ = (255 + (i_935_ - 100) * 327680 - (i_935_ - 100) * 5);
					}
				}
				if (anIntArray945[i] == 11) {
					int i_936_ = 150 - anIntArray947[i];
					if (i_936_ < 50) {
						i_933_ = 16777215 - i_936_ * 327685;
					} else if (i_936_ < 100) {
						i_933_ = 65280 + (i_936_ - 50) * 327685;
					} else if (i_936_ < 150) {
						i_933_ = 16777215 - (i_936_ - 100) * 327680;
					}
				}
				if (anIntArray946[i] == 0) {
					aFont_1061.method481(spriteDrawX, 452, spriteDrawY + 1, 0, string);
					aFont_1061.method481(spriteDrawX, 452, spriteDrawY, i_933_, string);
				}
				if (anIntArray946[i] == 1) {
					aFont_1061.method486(spriteDrawY + 1, (byte) 4, anInt1138, string, spriteDrawX, 0);
					aFont_1061.method486(spriteDrawY, (byte) 4, anInt1138, string, spriteDrawX, i_933_);
				}
				if (anIntArray946[i] == 2) {
					aFont_1061.method487(spriteDrawY + 1, 0, (byte) 1, string, spriteDrawX, anInt1138);
					aFont_1061.method487(spriteDrawY, i_933_, (byte) 1, string, spriteDrawX, anInt1138);
				}
				if (anIntArray946[i] == 3) {
					aFont_1061.method488(-601, string, 0, spriteDrawX, spriteDrawY + 1,
						150 - (anIntArray947[i]), anInt1138);
					aFont_1061.method488(-601, string, i_933_, spriteDrawX, spriteDrawY,
						150 - (anIntArray947[i]), anInt1138);
				}
				if (anIntArray946[i] == 4) {
					int i_937_ = aFont_1061.method484(string, (byte) -53);
					int i_938_ = (150 - anIntArray947[i]) * (i_937_ + 100) / 150;
					Renderer2D.method457(0, spriteDrawX - 50, 334, spriteDrawX + 50, true);
					aFont_1061.method485(2245, (spriteDrawX + 50 - i_938_), 0, spriteDrawY + 1, string);
					aFont_1061.method485(2245, (spriteDrawX + 50 - i_938_), i_933_, spriteDrawY, string);
					Renderer2D.method456();
				}
				if (anIntArray946[i] == 5) {
					int i_939_ = 150 - anIntArray947[i];
					int i_940_ = 0;
					if (i_939_ < 25) {
						i_940_ = i_939_ - 25;
					} else if (i_939_ > 125) {
						i_940_ = i_939_ - 125;
					}
					Renderer2D.method457(spriteDrawY - aFont_1061.anInt1506 - 1, 0, spriteDrawY + 5, 512,
						true);
					aFont_1061.method481(spriteDrawX, 452, (spriteDrawY + 1 + i_940_), 0, string);
					aFont_1061.method481(spriteDrawX, 452, spriteDrawY + i_940_, i_933_, string);
					Renderer2D.method456();
				}
			} else {
				aFont_1061.method481(spriteDrawX, 452, spriteDrawY + 1, 0, string);
				aFont_1061.method481(spriteDrawX, 452, spriteDrawY, 16776960, string);
			}
		}
	}

	public final void method122(int i) {
		while (i >= 0) {
			Client.aBoolean1242 = !Client.aBoolean1242;
		}
		if (aGraphicsBuffer_1159 == null) {
			method141(28614);
			aGraphicsBuffer_15 = null;
			aGraphicsBuffer_1198 = null;
			aGraphicsBuffer_1199 = null;
			aGraphicsBuffer_1200 = null;
			aGraphicsBuffer_1201 = null;
			aGraphicsBuffer_1202 = null;
			aGraphicsBuffer_1203 = null;
			aGraphicsBuffer_1204 = null;
			aGraphicsBuffer_1205 = null;
			aGraphicsBuffer_1206 = null;
			aGraphicsBuffer_1159 = new GraphicsBuffer(96, method11(), 479);
			aGraphicsBuffer_1157 = new GraphicsBuffer(156, method11(), 172);
			Renderer2D.method458(4);
			mapback.method501(0, 0);
			aGraphicsBuffer_1156 = new GraphicsBuffer(261, method11(), 190);
			aGraphicsBuffer_1158 = new GraphicsBuffer(334, method11(), 512);
			Renderer2D.method458(4);
			aGraphicsBuffer_1108 = new GraphicsBuffer(50, method11(), 496);
			aGraphicsBuffer_1109 = new GraphicsBuffer(37, method11(), 269);
			aGraphicsBuffer_1110 = new GraphicsBuffer(45, method11(), 249);
			aBoolean1046 = true;
			aGraphicsBuffer_1158.method230(false);
			Renderer3D.anIntArray1538 = anIntArray1002;
		}
	}

	public final void method123(int i) {
		Graphics graphics = method11().getGraphics();
		graphics.setColor(Color.black);
		i = 68 / i;
		graphics.fillRect(0, 0, 765, 503);
		this.method4(1);
		if (aBoolean1283) {
			aBoolean1243 = false;
			graphics.setFont(new java.awt.Font("Helvetica", 1, 16));
			graphics.setColor(Color.yellow);
			int i_941_ = 35;
			graphics.drawString("Sorry, an error has occured whilst loading RuneScape", 30, i_941_);
			i_941_ += 50;
			graphics.setColor(Color.white);
			graphics.drawString("To fix this try the following (in order):", 30, i_941_);
			i_941_ += 50;
			graphics.setColor(Color.white);
			graphics.setFont(new java.awt.Font("Helvetica", 1, 12));
			graphics.drawString("1: Try closing ALL open web-browser windows, and reloading", 30,
				i_941_);
			i_941_ += 30;
			graphics.drawString(
				"2: Try clearing your web-browsers cache from tools->internet options", 30, i_941_);
			i_941_ += 30;
			graphics.drawString("3: Try using a different game-world", 30, i_941_);
			i_941_ += 30;
			graphics.drawString("4: Try rebooting your computer", 30, i_941_);
			i_941_ += 30;
			graphics.drawString(
				"5: Try selecting a different version of Java from the play-game menu", 30, i_941_);
		}
		if (aBoolean1097) {
			aBoolean1243 = false;
			graphics.setFont(new java.awt.Font("Helvetica", 1, 20));
			graphics.setColor(Color.white);
			graphics.drawString("Error - unable to load game!", 50, 50);
			graphics.drawString("To play RuneScape make sure you play from", 50, 100);
			graphics.drawString("http://www.runescape.com", 50, 150);
		}
		if (aBoolean1016) {
			aBoolean1243 = false;
			graphics.setColor(Color.yellow);
			int i_942_ = 35;
			graphics.drawString("Error a copy of RuneScape already appears to be loaded", 30,
				i_942_);
			i_942_ += 50;
			graphics.setColor(Color.white);
			graphics.drawString("To fix this try the following (in order):", 30, i_942_);
			i_942_ += 50;
			graphics.setColor(Color.white);
			graphics.setFont(new java.awt.Font("Helvetica", 1, 12));
			graphics.drawString("1: Try closing ALL open web-browser windows, and reloading", 30,
				i_942_);
			i_942_ += 30;
			graphics.drawString("2: Try rebooting your computer, and reloading", 30, i_942_);
			i_942_ += 30;
		}
	}

	public final void method124(boolean bool) {
		try {
			if (socket != null) {
				socket.method224();
			}
		} catch (Exception exception) {
			/* empty */
		}
		socket = null;
		aBoolean1137 = false;
		anInt1225 = 0;
		aString1092 = "";
		aString1093 = "";
		method49(383);
		aBoolean1137 &= bool;
		aClass22_1164.method241((byte) 7);
		for (int i = 0; i < 4; i++) {
			aCollisionMapArray1260[i].method422();
		}
		System.gc();
		method50(false);
		anInt1327 = -1;
		anInt1270 = -1;
		anInt1128 = 0;
	}

	public final void method125(int i, String string, String string_943_) {
		if (i < 0) {
			if (aGraphicsBuffer_1158 != null) {
				aGraphicsBuffer_1158.method230(false);
				Renderer3D.anIntArray1538 = anIntArray1002;
				int i_944_ = 151;
				if (string != null) {
					i_944_ -= 7;
				}
				aFont_1060.method481(257, 452, i_944_, 0, string_943_);
				aFont_1060.method481(256, 452, i_944_ - 1, 16777215, string_943_);
				i_944_ += 15;
				if (string != null) {
					aFont_1060.method481(257, 452, i_944_, 0, string);
					aFont_1060.method481(256, 452, i_944_ - 1, 16777215, string);
				}
				aGraphicsBuffer_1158.method231(4, 4, aGraphics14, aBoolean1074);
			} else if (aGraphicsBuffer_15 != null) {
				aGraphicsBuffer_15.method230(false);
				Renderer3D.anIntArray1538 = anIntArray1003;
				int i_945_ = 251;
				int i_946_ = 300;
				int i_947_ = 50;
				Renderer2D.method460(i_947_, i_945_ - 5 - i_947_ / 2, 0, (byte) -24, i_946_,
					383 - i_946_ / 2);
				Renderer2D.method461(0, i_945_ - 5 - i_947_ / 2, i_947_, 16777215,
					383 - i_946_ / 2, i_946_);
				if (string != null) {
					i_945_ -= 7;
				}
				aFont_1060.method481(383, 452, i_945_, 0, string_943_);
				aFont_1060.method481(382, 452, i_945_ - 1, 16777215, string_943_);
				i_945_ += 15;
				if (string != null) {
					aFont_1060.method481(383, 452, i_945_, 0, string);
					aFont_1060.method481(382, 452, i_945_ - 1, 16777215, string);
				}
				aGraphicsBuffer_15.method231(0, 0, aGraphics14, aBoolean1074);
			}
		}
	}

	public final boolean method126(int i, byte i_948_) {
		if (i < 0) {
			return false;
		}
		int i_949_ = anIntArray981[i];
		if (i_948_ != 97) {
			throw new NullPointerException();
		}
		if (i_949_ >= 2000) {
			i_949_ -= 2000;
		}
		if (i_949_ == 762) {
			return true;
		}
		return false;
	}

	public final void method127() {
		anInt1056 = cryption.getNextKey();
		if (anInt1197 == 2) {
			getEntityScreenPos((anInt844 - anInt1040 << 7) + anInt847, anInt846 * 2,
 (anInt845
				- anInt1041 << 7)
				+ anInt848);
			if (spriteDrawX > -1 && Client.anInt1325 % 20 < 10) {
				headicons_hint[0].drawSprite(spriteDrawX - 12, spriteDrawY - 28);
			}
		}
	}

	public final void method9() {
		if (aBoolean1016 || aBoolean1283 || aBoolean1097) {
			method123(281);
		} else {
			Client.anInt1309++;
			if (!aBoolean1137) {
				method131(false);
			} else {
				method74(7);
			}
			anInt1094 = 0;
		}
	}

	public final void method128(boolean bool) {
		if (bool) {
			aPacket_964.putByte(23);
		}
		int i = anInt1305;
		int i_950_ = anInt1306;
		int i_951_ = anInt1307;
		int i_952_ = anInt1308;
		int i_953_ = 6116423;
		Renderer2D.method460(i_952_, i_950_, i_953_, (byte) -24, i_951_, i);
		Renderer2D.method460(16, i_950_ + 1, 0, (byte) -24, i_951_ - 2, i + 1);
		Renderer2D.method461(0, i_950_ + 18, i_952_ - 19, 0, i + 1, i_951_ - 2);
		aFont_1061.method485(2245, i + 3, i_953_, i_950_ + 14, "Choose Option");
		int i_954_ = anInt22;
		int i_955_ = anInt23;
		if (anInt1304 == 0) {
			i_954_ -= 4;
			i_955_ -= 4;
		}
		if (anInt1304 == 1) {
			i_954_ -= 553;
			i_955_ -= 205;
		}
		if (anInt1304 == 2) {
			i_954_ -= 17;
			i_955_ -= 357;
		}
		for (int i_956_ = 0; i_956_ < anInt1183; i_956_++) {
			int i_957_ = i_950_ + 31 + (anInt1183 - 1 - i_956_) * 15;
			int i_958_ = 16777215;
			if (i_954_ > i && i_954_ < i + i_951_ && i_955_ > i_957_ - 13 && i_955_ < i_957_ + 3) {
				i_958_ = 16776960;
			}
			aFont_1061.method489(i_958_, i + 3, i_957_, true, aStringArray1184[i_956_], -39629);
		}
	}

	public final int method129(int i, int i_959_, Interface iComponent) {
		if (i != 3) {
			return anInt1222;
		}
		if (iComponent.anIntArrayArray234 == null || i_959_ >= iComponent.anIntArrayArray234.length) {
			return -2;
		}
		try {
			int[] is = iComponent.anIntArrayArray234[i_959_];
			int i_960_ = 0;
			int i_961_ = 0;
			int i_962_ = 0;
			for (;;) {
				int i_963_ = is[i_961_++];
				int i_964_ = 0;
				int i_965_ = 0;
				if (i_963_ == 0) {
					return i_960_;
				}
				if (i_963_ == 1) {
					i_964_ = anIntArray1029[is[i_961_++]];
				}
				if (i_963_ == 2) {
					i_964_ = anIntArray1054[is[i_961_++]];
				}
				if (i_963_ == 3) {
					i_964_ = anIntArray843[is[i_961_++]];
				}
				if (i_963_ == 4) {
					Interface iComponent_966_ = Interface.method195(is[i_961_++]);
					int i_967_ = is[i_961_++];
					if (i_967_ >= 0 && i_967_ < ItemDefinition.anInt335
						&& (!ItemDefinition.method212(i_967_).aBoolean377 || Client.aBoolean925)) {
						for (int i_968_ = 0; i_968_ < iComponent_966_.anIntArray269.length; i_968_++) {
							if (iComponent_966_.anIntArray269[i_968_] == i_967_ + 1) {
								i_964_ += iComponent_966_.anIntArray224[i_968_];
							}
						}
					}
				}
				if (i_963_ == 5) {
					i_964_ = anIntArray1039[is[i_961_++]];
				}
				if (i_963_ == 6) {
					i_964_ = Client.anIntArray952[anIntArray1054[is[i_961_++]] - 1];
				}
				if (i_963_ == 7) {
					i_964_ = anIntArray1039[is[i_961_++]] * 100 / 46875;
				}
				if (i_963_ == 8) {
					i_964_ = ((Player) Client.myPlayer).anInt1753;
				}
				if (i_963_ == 9) {
					for (int i_969_ = 0; i_969_ < Skills.skillCount; i_969_++) {
						if (Skills.skillEnabled[i_969_]) {
							i_964_ += anIntArray1054[i_969_];
						}
					}
				}
				if (i_963_ == 10) {
					Interface iComponent_970_ = Interface.method195(is[i_961_++]);
					int i_971_ = is[i_961_++] + 1;
					if (i_971_ >= 0 && i_971_ < ItemDefinition.anInt335
						&& (!ItemDefinition.method212(i_971_).aBoolean377 || Client.aBoolean925)) {
						for (int element : iComponent_970_.anIntArray269) {
							if (element == i_971_) {
								i_964_ = 999999999;
								break;
							}
						}
					}
				}
				if (i_963_ == 11) {
					i_964_ = anInt1324;
				}
				if (i_963_ == 12) {
					i_964_ = anInt1030;
				}
				if (i_963_ == 13) {
					int i_973_ = anIntArray1039[is[i_961_++]];
					int i_974_ = is[i_961_++];
					i_964_ = (i_973_ & 1 << i_974_) != 0 ? 1 : 0;
				}
				if (i_963_ == 14) {
					int i_975_ = is[i_961_++];
					VarBit varBit = VarBit.aVarBitArray824[i_975_];
					int i_976_ = varBit.anInt826;
					int i_977_ = varBit.anInt827;
					int i_978_ = varBit.anInt828;
					int i_979_ = Client.anIntArray1214[i_978_ - i_977_];
					i_964_ = anIntArray1039[i_976_] >> i_977_ & i_979_;
				}
				if (i_963_ == 15) {
					i_965_ = 1;
				}
				if (i_963_ == 16) {
					i_965_ = 2;
				}
				if (i_963_ == 17) {
					i_965_ = 3;
				}
				if (i_963_ == 18) {
					i_964_ = (((ObjectInstance) Client.myPlayer).anInt1610 >> 7)
						+ anInt1040;
				}
				if (i_963_ == 19) {
					i_964_ = (((ObjectInstance) Client.myPlayer).anInt1611 >> 7)
						+ anInt1041;
				}
				if (i_963_ == 20) {
					i_964_ = is[i_961_++];
				}
				if (i_965_ == 0) {
					if (i_962_ == 0) {
						i_960_ += i_964_;
					}
					if (i_962_ == 1) {
						i_960_ -= i_964_;
					}
					if (i_962_ == 2 && i_964_ != 0) {
						i_960_ /= i_964_;
					}
					if (i_962_ == 3) {
						i_960_ *= i_964_;
					}
					i_962_ = 0;
				} else {
					i_962_ = i_965_;
				}
			}
		} catch (Exception exception) {
			return -1;
		}
	}

	public final void method130(int i, boolean bool, Sprite sprite, int i_980_) {
		if (sprite != null) {
			int i_981_ = anInt1252 + anInt916 & 0x7ff;
			int i_982_ = i_980_ * i_980_ + i * i;
			if (i_982_ <= 6400) {
				int i_983_ = Model.anIntArray1710[i_981_];
				int i_984_ = Model.anIntArray1711[i_981_];
				i_983_ = i_983_ * 256 / (anInt1233 + 256);
				i_984_ = i_984_ * 256 / (anInt1233 + 256);
				if (!bool) {
					opcode = inputStream.getUByte();
				}
				int i_985_ = i * i_983_ + i_980_ * i_984_ >> 16;
				int i_986_ = i * i_984_ - i_980_ * i_983_ >> 16;
				if (i_982_ > 2500) {
					sprite.method478(mapback, (83 - i_986_ - sprite.trimHeight / 2 - 4), (i_985_
						+ 94 - sprite.trimWidth / 2 + 4));
				} else {
					sprite.drawSprite((i_985_ + 94
						- sprite.trimWidth / 2 + 4), (83 - i_986_ - sprite.trimHeight / 2 - 4));
				}
			}
		}
	}

	public final void method131(boolean bool) {
		method64(-188);
		aGraphicsBuffer_1200.method230(false);
		aIndexedSprite_1292.method501(0, 0);
		int i_987_ = 360;
		int i_988_ = 200;
		if (anInt1225 == 0) {
			int i_990_ = i_988_ / 2 + 80;
			aFont_1059.method482(true, 7711145, i_990_, i_987_ / 2,
				(aClass32_Sub1_1291.aString1347));
			i_990_ = i_988_ / 2 - 20;
			aFont_1061.method482(true, 16776960, i_990_, i_987_ / 2, "Welcome to RuneScape");
			i_990_ += 30;
			int i_991_ = i_987_ / 2 - 80;
			int i_992_ = i_988_ / 2 + 20;
			aIndexedSprite_1293.method501(i_992_ - 20, i_991_ - 73);
			aFont_1061.method482(true, 16777215, i_992_ + 5, i_991_, "New User");
			i_991_ = i_987_ / 2 + 80;
			aIndexedSprite_1293.method501(i_992_ - 20, i_991_ - 73);
			aFont_1061.method482(true, 16777215, i_992_ + 5, i_991_, "Existing User");
		}
		if (anInt1225 == 2) {
			int i_993_ = i_988_ / 2 - 40;
			if (aString957.length() > 0) {
				aFont_1061.method482(true, 16776960, i_993_ - 15, i_987_ / 2, aString957);
				aFont_1061.method482(true, 16776960, i_993_, i_987_ / 2, aString958);
				i_993_ += 30;
			} else {
				aFont_1061.method482(true, 16776960, i_993_ - 7, i_987_ / 2, aString958);
				i_993_ += 30;
			}
			aFont_1061.method489(16777215, i_987_ / 2 - 90, i_993_, true, ("Username: "
				+ aString1092 + ((anInt977 == 0 & Client.anInt1325 % 40 < 20) ? "@yel@|" : "")),
				-39629);
			i_993_ += 15;
			aFont_1061.method489(16777215, i_987_ / 2 - 88, i_993_, true,
				("Password: " + TextUtil.method304(2934, aString1093) + (anInt977 == 1
					& Client.anInt1325 % 40 < 20 ? "@yel@|" : "")), -39629);
			i_993_ += 15;
			if (!bool) {
				int i_994_ = i_987_ / 2 - 80;
				int i_995_ = i_988_ / 2 + 50;
				aIndexedSprite_1293.method501(i_995_ - 20, i_994_ - 73);
				aFont_1061.method482(true, 16777215, i_995_ + 5, i_994_, "Login");
				i_994_ = i_987_ / 2 + 80;
				aIndexedSprite_1293.method501(i_995_ - 20, i_994_ - 73);
				aFont_1061.method482(true, 16777215, i_995_ + 5, i_994_, "Cancel");
			}
		}
		if (anInt1225 == 3) {
			aFont_1061.method482(true, 16776960, i_988_ / 2 - 60, i_987_ / 2,
				"Create a free account");
			int i_996_ = i_988_ / 2 - 35;
			aFont_1061.method482(true, 16777215, i_996_, i_987_ / 2,
				"To create a new account you need to");
			i_996_ += 15;
			aFont_1061.method482(true, 16777215, i_996_, i_987_ / 2,
				"go back to the main RuneScape webpage");
			i_996_ += 15;
			aFont_1061.method482(true, 16777215, i_996_, i_987_ / 2,
				"and choose the 'create account'");
			i_996_ += 15;
			aFont_1061.method482(true, 16777215, i_996_, i_987_ / 2,
				"button near the top of that page.");
			i_996_ += 15;
			int i_997_ = i_987_ / 2;
			int i_998_ = i_988_ / 2 + 50;
			aIndexedSprite_1293.method501(i_998_ - 20, i_997_ - 73);
			aFont_1061.method482(true, 16777215, i_998_ + 5, i_997_, "Cancel");
		}
		aGraphicsBuffer_1200.method231(171, 202, aGraphics14, aBoolean1074);
		if (aBoolean1046) {
			aBoolean1046 = false;
			aGraphicsBuffer_1198.method231(0, 128, aGraphics14, aBoolean1074);
			aGraphicsBuffer_1199.method231(371, 202, aGraphics14, aBoolean1074);
			aGraphicsBuffer_1203.method231(265, 0, aGraphics14, aBoolean1074);
			aGraphicsBuffer_1204.method231(265, 562, aGraphics14, aBoolean1074);
			aGraphicsBuffer_1205.method231(171, 128, aGraphics14, aBoolean1074);
			aGraphicsBuffer_1206.method231(171, 562, aGraphics14, aBoolean1074);
		}
	}

	private final void method132(Packet packet, int i, boolean bool) {
		if (bool) {
			anInt1140 = 287;
		}
		while (packet.bitPos + 21 < i * 8) {
			int i_999_ = packet.readBits(14);
			if (i_999_ == 16383) {
				break;
			}
			if (totalNpcs[i_999_] == null) {
				totalNpcs[i_999_] = new Npc();
			}
			Npc npc = totalNpcs[i_999_];
			((Client) this).anIntArray1134[npcCount++] = i_999_;
			((ObjectInstance) npc).anInt1585 = Client.anInt1325;
			int i_1000_ = packet.readBits(1);
			if (i_1000_ == 1) {
				anIntArray974[anInt973++] = i_999_;
			}
			int i_1001_ = packet.readBits(5);
			if (i_1001_ > 15) {
				i_1001_ -= 32;
			}
			int i_1002_ = packet.readBits(5);
			if (i_1002_ > 15) {
				i_1002_ -= 32;
			}
			int i_1003_ = packet.readBits(1);
			((Npc) npc).npc = NpcDefinition.method375(packet.readBits(13));
			((ObjectInstance) npc).anInt1601 = (((Npc) npc).npc.aByte642);
			((ObjectInstance) npc).anInt1600 = (((Npc) npc).npc.anInt651);
			((ObjectInstance) npc).anInt1619 = (((Npc) npc).npc.anInt645);
			((ObjectInstance) npc).anInt1620 = (((Npc) npc).npc.anInt643);
			((ObjectInstance) npc).anInt1621 = (((Npc) npc).npc.anInt641);
			((ObjectInstance) npc).anInt1622 = (((Npc) npc).npc.anInt633);
			((ObjectInstance) npc).anInt1634 = (((Npc) npc).npc.anInt621);
			npc.method579((((ObjectInstance) Client.myPlayer).anIntArray1587[0])
				+ i_1001_, (byte) 5, i_1003_ == 1,
				(((ObjectInstance) Client.myPlayer).anIntArray1586[0]) + i_1002_);
		}
		packet.finishBitAccess();
	}

	public final void method133(Packet packet, int i, int i_1004_) {
		if (i != 0) {
			aDequeArrayArrayArray1323 = null;
		}
		if (i_1004_ == 203) {
			int i_1005_ = packet.getUShort();
			int i_1006_ = packet.getUByte();
			int i_1007_ = i_1006_ >> 2;
			int i_1008_ = i_1006_ & 0x3;
			int i_1009_ = anIntArray1032[i_1007_];
			int i_1010_ = packet.getByteC();
			int i_1011_ = packet.getUByteA();
			int i_1012_ = anInt989 + (i_1011_ >> 4 & 0x7);
			int i_1013_ = anInt990 + (i_1011_ & 0x7);
			int i_1014_ = packet.getByteA();
			int i_1015_ = packet.getULEShortA1();
			int i_1016_ = packet.getULEShort();
			int i_1017_ = packet.getByte();
			int i_1018_ = packet.getByteA();
			int i_1019_ = packet.getUShort();
			Player player;
			if (i_1016_ == anInt961) {
				player = Client.myPlayer;
			} else {
				player = totalPlayers[i_1016_];
			}
			if (player != null) {
				ObjectDefinition objectDefinition = ObjectDefinition.method434(i_1005_);
				int i_1020_ = anIntArrayArrayArray891[anInt1091][i_1012_][i_1013_];
				int i_1021_ = anIntArrayArrayArray891[anInt1091][i_1012_ + 1][i_1013_];
				int i_1022_ = (anIntArrayArrayArray891[anInt1091][i_1012_ + 1][i_1013_ + 1]);
				int i_1023_ = anIntArrayArrayArray891[anInt1091][i_1012_][i_1013_ + 1];
				Model model = objectDefinition.method442(i_1007_, i_1008_, i_1020_, i_1021_,
					i_1022_, i_1023_, -1);
				if (model != null) {
					method145(true, anInt1091, i_1012_, 0, i_1015_ + 1, 0, -1, i_1019_ + 1,
						i_1009_, i_1013_);
					((Player) player).anInt1764 = i_1019_ + Client.anInt1325;
					((Player) player).anInt1765 = i_1015_ + Client.anInt1325;
					((Player) player).aModel_1746 = model;
					int i_1024_ = objectDefinition.anInt801;
					int i_1025_ = objectDefinition.anInt775;
					if (i_1008_ == 1 || i_1008_ == 3) {
						i_1024_ = objectDefinition.anInt775;
						i_1025_ = objectDefinition.anInt801;
					}
					((Player) player).anInt1743 = i_1012_ * 128 + i_1024_ * 64;
					((Player) player).anInt1745 = i_1013_ * 128 + i_1025_ * 64;
					((Player) player).anInt1744 = method110(((Player) player).anInt1745,
						((Player) player).anInt1743, (byte) 9, anInt1091);
					if (i_1014_ > i_1010_) {
						int i_1026_ = i_1014_;
						i_1014_ = i_1010_;
						i_1010_ = i_1026_;
					}
					if (i_1018_ > i_1017_) {
						int i_1027_ = i_1018_;
						i_1018_ = i_1017_;
						i_1017_ = i_1027_;
					}
					((Player) player).anInt1768 = i_1012_ + i_1014_;
					((Player) player).anInt1770 = i_1012_ + i_1010_;
					((Player) player).anInt1769 = i_1013_ + i_1018_;
					((Player) player).anInt1771 = i_1013_ + i_1017_;
				}
			}
		}
		if (i_1004_ == 106) {
			int i_1028_ = packet.getUByteA();
			int i_1029_ = anInt989 + (i_1028_ >> 4 & 0x7);
			int i_1030_ = anInt990 + (i_1028_ & 0x7);
			int i_1031_ = packet.getULEShortA2();
			int i_1032_ = packet.getULEShortA1();
			int i_1033_ = packet.getULEShortA1();
			if (i_1029_ >= 0 && i_1030_ >= 0 && i_1029_ < 104 && i_1030_ < 104
				&& i_1033_ != anInt961) {
				Class50_Sub1_Sub4_Sub1 class50_sub1_sub4_sub1 = new Class50_Sub1_Sub4_Sub1();
				class50_sub1_sub4_sub1.anInt1550 = i_1032_;
				class50_sub1_sub4_sub1.anInt1552 = i_1031_;
				if (aDequeArrayArrayArray1323[anInt1091][i_1029_][i_1030_] == null) {
					aDequeArrayArrayArray1323[anInt1091][i_1029_][i_1030_] = new Deque(true);
				}
				aDequeArrayArrayArray1323[anInt1091][i_1029_][i_1030_]
					.method155(class50_sub1_sub4_sub1);
				method26(i_1029_, i_1030_);
			}
		} else if (i_1004_ == 142) {
			int i_1034_ = packet.getUShort();
			int i_1035_ = packet.getUByteA();
			int i_1036_ = i_1035_ >> 2;
			int i_1037_ = i_1035_ & 0x3;
			int i_1038_ = anIntArray1032[i_1036_];
			int i_1039_ = packet.getUByte();
			int i_1040_ = anInt989 + (i_1039_ >> 4 & 0x7);
			int i_1041_ = anInt990 + (i_1039_ & 0x7);
			if (i_1040_ >= 0 && i_1041_ >= 0 && i_1040_ < 103 && i_1041_ < 103) {
				int i_1042_ = anIntArrayArrayArray891[anInt1091][i_1040_][i_1041_];
				int i_1043_ = anIntArrayArrayArray891[anInt1091][i_1040_ + 1][i_1041_];
				int i_1044_ = (anIntArrayArrayArray891[anInt1091][i_1040_ + 1][i_1041_ + 1]);
				int i_1045_ = anIntArrayArrayArray891[anInt1091][i_1040_][i_1041_ + 1];
				if (i_1038_ == 0) {
					Class44 class44 = aClass22_1164.method263(anInt1091, 17734, i_1040_, i_1041_);
					if (class44 != null) {
						int i_1046_ = class44.anInt726 >> 14 & 0x7fff;
						if (i_1036_ == 2) {
							class44.aClass50_Sub1_Sub4_724 = new Class50_Sub1_Sub4_Sub5(i_1034_,
								i_1044_, i_1045_, i_1043_, 2, (byte) 3, i_1046_, false, i_1042_,
								i_1037_ + 4);
							class44.aClass50_Sub1_Sub4_725 = new Class50_Sub1_Sub4_Sub5(i_1034_,
								i_1044_, i_1045_, i_1043_, 2, (byte) 3, i_1046_, false, i_1042_,
								(i_1037_ + 1 & 0x3));
						} else {
							class44.aClass50_Sub1_Sub4_724 = new Class50_Sub1_Sub4_Sub5(i_1034_,
								i_1044_, i_1045_, i_1043_, i_1036_, (byte) 3, i_1046_, false,
								i_1042_, i_1037_);
						}
					}
				}
				if (i_1038_ == 1) {
					Class35 class35 = aClass22_1164.method264(anInt1091, i_1041_, i_1040_, false);
					if (class35 != null) {
						class35.aClass50_Sub1_Sub4_608 = new Class50_Sub1_Sub4_Sub5(i_1034_,
							i_1044_, i_1045_, i_1043_, 4, (byte) 3,
							(class35.anInt609 >> 14) & 0x7fff, false, i_1042_, 0);
					}
				}
				if (i_1038_ == 2) {
					Class5 class5 = aClass22_1164.method265(i_1040_, (byte) 32, i_1041_, anInt1091);
					if (i_1036_ == 11) {
						i_1036_ = 10;
					}
					if (class5 != null) {
						class5.aClass50_Sub1_Sub4_117 = new Class50_Sub1_Sub4_Sub5(i_1034_,
							i_1044_, i_1045_, i_1043_, i_1036_, (byte) 3,
							(class5.anInt125 >> 14 & 0x7fff), false, i_1042_, i_1037_);
					}
				}
				if (i_1038_ == 3) {
					Class28 class28 = aClass22_1164.method266(anInt1091, i_1041_, 0, i_1040_);
					if (class28 != null) {
						class28.aClass50_Sub1_Sub4_570 = new Class50_Sub1_Sub4_Sub5(i_1034_,
							i_1044_, i_1045_, i_1043_, 22, (byte) 3,
							(class28.anInt571 >> 14) & 0x7fff, false, i_1042_, i_1037_);
					}
				}
			}
		} else if (i_1004_ == 107) {
			int i_1047_ = packet.getUShort();
			int i_1048_ = packet.getUByteC();
			int i_1049_ = anInt989 + (i_1048_ >> 4 & 0x7);
			int i_1050_ = anInt990 + (i_1048_ & 0x7);
			int i_1051_ = packet.getULEShortA1();
			if (i_1049_ >= 0 && i_1050_ >= 0 && i_1049_ < 104 && i_1050_ < 104) {
				Class50_Sub1_Sub4_Sub1 class50_sub1_sub4_sub1 = new Class50_Sub1_Sub4_Sub1();
				class50_sub1_sub4_sub1.anInt1550 = i_1047_;
				class50_sub1_sub4_sub1.anInt1552 = i_1051_;
				if (aDequeArrayArrayArray1323[anInt1091][i_1049_][i_1050_] == null) {
					aDequeArrayArrayArray1323[anInt1091][i_1049_][i_1050_] = new Deque(true);
				}
				aDequeArrayArrayArray1323[anInt1091][i_1049_][i_1050_]
					.method155(class50_sub1_sub4_sub1);
				method26(i_1049_, i_1050_);
			}
		} else if (i_1004_ == 121) {
			int i_1052_ = packet.getUByte();
			int i_1053_ = anInt989 + (i_1052_ >> 4 & 0x7);
			int i_1054_ = anInt990 + (i_1052_ & 0x7);
			int i_1055_ = packet.getUShort();
			int i_1056_ = packet.getUShort();
			int i_1057_ = packet.getUShort();
			if (i_1053_ >= 0 && i_1054_ >= 0 && i_1053_ < 104 && i_1054_ < 104) {
				Deque deque = aDequeArrayArrayArray1323[anInt1091][i_1053_][i_1054_];
				if (deque != null) {
					for (Class50_Sub1_Sub4_Sub1 class50_sub1_sub4_sub1 = (Class50_Sub1_Sub4_Sub1) deque
						.method158(); class50_sub1_sub4_sub1 != null; class50_sub1_sub4_sub1 = (Class50_Sub1_Sub4_Sub1) deque
						.method160(1)) {
						if (class50_sub1_sub4_sub1.anInt1550 == (i_1055_ & 0x7fff)
							&& class50_sub1_sub4_sub1.anInt1552 == i_1056_) {
							class50_sub1_sub4_sub1.anInt1552 = i_1057_;
							break;
						}
					}
					method26(i_1053_, i_1054_);
				}
			}
		} else if (i_1004_ == 181) {
			int i_1058_ = packet.getUByte();
			int i_1059_ = anInt989 + (i_1058_ >> 4 & 0x7);
			int i_1060_ = anInt990 + (i_1058_ & 0x7);
			int i_1061_ = i_1059_ + packet.getByte();
			int i_1062_ = i_1060_ + packet.getByte();
			int i_1063_ = packet.getShort();
			int i_1064_ = packet.getUShort();
			int i_1065_ = packet.getUByte() * 4;
			int i_1066_ = packet.getUByte() * 4;
			int i_1067_ = packet.getUShort();
			int i_1068_ = packet.getUShort();
			int i_1069_ = packet.getUByte();
			int i_1070_ = packet.getUByte();
			if (i_1059_ >= 0 && i_1060_ >= 0 && i_1059_ < 104 && i_1060_ < 104 && i_1061_ >= 0
				&& i_1062_ >= 0 && i_1061_ < 104 && i_1062_ < 104 && i_1064_ != 65535) {
				i_1059_ = i_1059_ * 128 + 64;
				i_1060_ = i_1060_ * 128 + 64;
				i_1061_ = i_1061_ * 128 + 64;
				i_1062_ = i_1062_ * 128 + 64;
				Class50_Sub1_Sub4_Sub2 class50_sub1_sub4_sub2 = new Class50_Sub1_Sub4_Sub2(
					anInt1091, i_1066_, i_1070_, i_1060_, i_1064_, i_1068_ + Client.anInt1325,
					i_1069_, i_1063_, (byte) -41,
					(method110(i_1060_, i_1059_, (byte) 9, anInt1091) - i_1065_), i_1059_, i_1067_
						+ Client.anInt1325);
				class50_sub1_sub4_sub2.method573(i_1061_, i_1062_,
					(method110(i_1062_, i_1061_, (byte) 9, anInt1091) - i_1066_), i_1067_
						+ Client.anInt1325, 0);
				aDeque_1282.method155(class50_sub1_sub4_sub2);
			}
		} else {
			if (i_1004_ == 41) {
				int i_1071_ = packet.getUByte();
				int i_1072_ = anInt989 + (i_1071_ >> 4 & 0x7);
				int i_1073_ = anInt990 + (i_1071_ & 0x7);
				int i_1074_ = packet.getUShort();
				int i_1075_ = packet.getUByte();
				int i_1076_ = i_1075_ >> 4 & 0xf;
				int i_1077_ = i_1075_ & 0x7;
				if ((((ObjectInstance) Client.myPlayer).anIntArray1586[0] >= i_1072_
					- i_1076_)
					&& (((ObjectInstance) Client.myPlayer).anIntArray1586[0] <= i_1072_
						+ i_1076_)
					&& (((ObjectInstance) Client.myPlayer).anIntArray1587[0] >= i_1073_
						- i_1076_)
					&& (((ObjectInstance) Client.myPlayer).anIntArray1587[0] <= i_1073_
						+ i_1076_) && aBoolean1301 && !Client.aBoolean926 && anInt1035 < 50) {
					anIntArray1090[anInt1035] = i_1074_;
					anIntArray1321[anInt1035] = i_1077_;
					anIntArray1259[anInt1035] = Class38.anIntArray669[i_1074_];
					anInt1035++;
				}
			}
			if (i_1004_ == 59) {
				int i_1078_ = packet.getUByte();
				int i_1079_ = anInt989 + (i_1078_ >> 4 & 0x7);
				int i_1080_ = anInt990 + (i_1078_ & 0x7);
				int i_1081_ = packet.getUShort();
				int i_1082_ = packet.getUByte();
				int i_1083_ = packet.getUShort();
				if (i_1079_ >= 0 && i_1080_ >= 0 && i_1079_ < 104 && i_1080_ < 104) {
					i_1079_ = i_1079_ * 128 + 64;
					i_1080_ = i_1080_ * 128 + 64;
					Class50_Sub1_Sub4_Sub6 class50_sub1_sub4_sub6 = new Class50_Sub1_Sub4_Sub6(
						i_1079_, anInt1091,
						(method110(i_1080_, i_1079_, (byte) 9, anInt1091) - i_1082_), i_1083_,
						i_1081_, Client.anInt1325, i_1080_, 10709);
					aDeque_1210.method155(class50_sub1_sub4_sub6);
				}
			} else if (i_1004_ == 152) {
				int i_1084_ = packet.getUByteC();
				int i_1085_ = i_1084_ >> 2;
				int i_1086_ = i_1084_ & 0x3;
				int i_1087_ = anIntArray1032[i_1085_];
				int i_1088_ = packet.getULEShortA2();
				int i_1089_ = packet.getUByteA();
				int i_1090_ = anInt989 + (i_1089_ >> 4 & 0x7);
				int i_1091_ = anInt990 + (i_1089_ & 0x7);
				if (i_1090_ >= 0 && i_1091_ >= 0 && i_1090_ < 104 && i_1091_ < 104) {
					method145(true, anInt1091, i_1090_, i_1086_, -1, i_1085_, i_1088_, 0, i_1087_,
						i_1091_);
				}
			} else if (i_1004_ == 208) {
				int i_1092_ = packet.getULEShortA1();
				int i_1093_ = packet.getUByteA();
				int i_1094_ = anInt989 + (i_1093_ >> 4 & 0x7);
				int i_1095_ = anInt990 + (i_1093_ & 0x7);
				if (i_1094_ >= 0 && i_1095_ >= 0 && i_1094_ < 104 && i_1095_ < 104) {
					Deque deque = (aDequeArrayArrayArray1323[anInt1091][i_1094_][i_1095_]);
					if (deque != null) {
						for (Class50_Sub1_Sub4_Sub1 class50_sub1_sub4_sub1 = (Class50_Sub1_Sub4_Sub1) deque
							.method158(); class50_sub1_sub4_sub1 != null; class50_sub1_sub4_sub1 = ((Class50_Sub1_Sub4_Sub1) deque
							.method160(1))) {
							if (class50_sub1_sub4_sub1.anInt1550 == (i_1092_ & 0x7fff)) {
								class50_sub1_sub4_sub1.method453();
								break;
							}
						}
						if (deque.method158() == null) {
							aDequeArrayArrayArray1323[anInt1091][i_1094_][i_1095_] = null;
						}
						method26(i_1094_, i_1095_);
					}
				}
			} else if (i_1004_ == 88) {
				int i_1096_ = packet.getUByteS();
				int i_1097_ = anInt989 + (i_1096_ >> 4 & 0x7);
				int i_1098_ = anInt990 + (i_1096_ & 0x7);
				int i_1099_ = packet.getUByteS();
				int i_1100_ = i_1099_ >> 2;
				int i_1101_ = i_1099_ & 0x3;
				int i_1102_ = anIntArray1032[i_1100_];
				if (i_1097_ >= 0 && i_1098_ >= 0 && i_1097_ < 104 && i_1098_ < 104) {
					method145(true, anInt1091, i_1097_, i_1101_, -1, i_1100_, -1, 0, i_1102_,
						i_1098_);
				}
			}
		}
	}

	public final void method134(byte i) {
		aGraphicsBuffer_1156.method230(false);
		Renderer3D.anIntArray1538 = anIntArray1001;
		invback.method501(0, 0);
		if (anInt1089 != -1) {
			method142(0, 0, Interface.method195(anInt1089), 0, 8);
		} else if (anIntArray1081[anInt1285] != -1) {
			method142(0, 0, Interface.method195(anIntArray1081[anInt1285]), 0, 8);
		}
		if (aBoolean1065 && anInt1304 == 1) {
			method128(false);
		}
		aGraphicsBuffer_1156.method231(205, 553, aGraphics14, aBoolean1074);
		aGraphicsBuffer_1158.method230(false);
		Renderer3D.anIntArray1538 = anIntArray1002;
		if (i != 7) {
			/* empty */
		}
	}

	private static final String method135(int i, int i_1103_) {
		String string = String.valueOf(i_1103_);
		if (i != 0) {
			throw new NullPointerException();
		}
		for (int i_1104_ = string.length() - 3; i_1104_ > 0; i_1104_ -= 3) {
			string = (string.substring(0, i_1104_) + "," + string.substring(i_1104_));
		}
		if (string.length() > 8) {
			string = ("@gre@" + string.substring(0, string.length() - 8) + " million @whi@("
				+ string + ")");
		} else if (string.length() > 4) {
			string = ("@cya@" + string.substring(0, string.length() - 4) + "K @whi@(" + string + ")");
		}
		return " " + string;
	}

	public final void worldToScreen(ObjectInstance objectInstance, int i) {
		getEntityScreenPos(((ObjectInstance) objectInstance).anInt1610, i,
			((ObjectInstance) objectInstance).anInt1611);
	}

	public final void getEntityScreenPos(int i, int i_1105_, int i_1106_) {
		if (i < 128 || i_1106_ < 128 || i > 13056 || i_1106_ > 13056) {
			spriteDrawX = -1;
			spriteDrawY = -1;
		} else {
			int i_1108_ = method110(i_1106_, i, (byte) 9, anInt1091) - i_1105_;
			i -= anInt1216;
			i_1108_ -= anInt1217;
			i_1106_ -= anInt1218;
			int i_1109_ = Model.anIntArray1710[anInt1219];
			int i_1110_ = Model.anIntArray1711[anInt1219];
			int i_1111_ = Model.anIntArray1710[anInt1220];
			int i_1112_ = Model.anIntArray1711[anInt1220];
			int i_1113_ = i_1106_ * i_1111_ + i * i_1112_ >> 16;
			i_1106_ = i_1106_ * i_1112_ - i * i_1111_ >> 16;
			i = i_1113_;
			i_1113_ = i_1108_ * i_1110_ - i_1106_ * i_1109_ >> 16;
			i_1106_ = i_1108_ * i_1109_ + i_1106_ * i_1110_ >> 16;
			i_1108_ = i_1113_;
			if (i_1106_ >= 50) {
				spriteDrawX = Renderer3D.anInt1532 + (i << 9) / i_1106_;
				spriteDrawY = (Renderer3D.anInt1533 + (i_1108_ << 9) / i_1106_);
			} else {
				spriteDrawX = -1;
				spriteDrawY = -1;
			}
		}
	}

	public void method138(boolean bool) {
		System.out.println("============");
		System.out.println("flame-cycle:" + anInt1101);
		if (aClass32_Sub1_1291 != null) {
			System.out.println("Od-cycle:" + aClass32_Sub1_1291.anInt1348);
		}
		System.out.println("loop-cycle:" + Client.anInt1325);
		System.out.println("draw-cycle:" + Client.anInt1309);
		System.out.println("ptype:" + opcode);
		System.out.println("psize:" + packetSize);
		if (bool) {
			aBoolean1028 = !aBoolean1028;
		}
		if (socket != null) {
			socket.method229(false);
		}
		aBoolean11 = true;
	}

	public final Component method11() {
		if (Signlink.mainapp != null) {
			return Signlink.mainapp;
		}
		if (frame != null) {
			return frame;
		}
		return this;
	}

	public final void drawLoadingText(int i, String string) {
		anInt1322 = i;
		aString1027 = string;
		method64(-188);
		if (aArchive_888 == null) {
			super.drawLoadingText(i, string);
		} else {
			aGraphicsBuffer_1200.method230(false);
			int i_1115_ = 360;
			int i_1116_ = 200;
			int i_1117_ = 20;
			aFont_1061.method481(i_1115_ / 2, 452, i_1116_ / 2 - 26 - i_1117_, 16777215,
				"RuneScape is loading - please wait...");
			int i_1118_ = i_1116_ / 2 - 18 - i_1117_;
			Renderer2D.method461(0, i_1118_, 34, 9179409, i_1115_ / 2 - 152, 304);
			Renderer2D.method461(0, i_1118_ + 1, 32, 0, i_1115_ / 2 - 151, 302);
			Renderer2D.method460(30, i_1118_ + 2, 9179409, (byte) -24, i * 3, i_1115_ / 2 - 150);
			Renderer2D.method460(30, i_1118_ + 2, 0, (byte) -24, 300 - i * 3, i_1115_ / 2 - 150 + i
				* 3);
			aFont_1061.method481(i_1115_ / 2, 452, i_1116_ / 2 + 5 - i_1117_, 16777215, string);
			aGraphicsBuffer_1200.method231(171, 202, aGraphics14, aBoolean1074);
			if (aBoolean1046) {
				aBoolean1046 = false;
				if (!aBoolean1243) {
					aGraphicsBuffer_1201.method231(0, 0, aGraphics14, aBoolean1074);
					aGraphicsBuffer_1202.method231(0, 637, aGraphics14, aBoolean1074);
				}
				aGraphicsBuffer_1198.method231(0, 128, aGraphics14, aBoolean1074);
				aGraphicsBuffer_1199.method231(371, 202, aGraphics14, aBoolean1074);
				aGraphicsBuffer_1203.method231(265, 0, aGraphics14, aBoolean1074);
				aGraphicsBuffer_1204.method231(265, 562, aGraphics14, aBoolean1074);
				aGraphicsBuffer_1205.method231(171, 128, aGraphics14, aBoolean1074);
				aGraphicsBuffer_1206.method231(171, 562, aGraphics14, aBoolean1074);
			}
		}
	}

	public final void method139(boolean bool) {
		byte[] is = aArchive_888.method154("title.dat", null);
		Sprite sprite = new Sprite(is, this);
		aGraphicsBuffer_1201.method230(false);
		sprite.method470(0, 0);
		aGraphicsBuffer_1202.method230(false);
		sprite.method470(0, -637);
		aGraphicsBuffer_1198.method230(false);
		sprite.method470(0, -128);
		aGraphicsBuffer_1199.method230(false);
		sprite.method470(-371, -202);
		aGraphicsBuffer_1200.method230(false);
		sprite.method470(-171, -202);
		aGraphicsBuffer_1203.method230(false);
		sprite.method470(-265, 0);
		aGraphicsBuffer_1204.method230(false);
		sprite.method470(-265, -562);
		aGraphicsBuffer_1205.method230(false);
		sprite.method470(-171, -128);
		aGraphicsBuffer_1206.method230(false);
		sprite.method470(-171, -562);
		int[] is_1119_ = new int[sprite.width];
		for (int i = 0; i < sprite.height; i++) {
			for (int i_1120_ = 0; i_1120_ < sprite.width; i_1120_++) {
				is_1119_[i_1120_] = (sprite.pixels[(sprite.width - i_1120_ - 1 + sprite.width
					* i)]);
			}
			for (int i_1121_ = 0; i_1121_ < sprite.width; i_1121_++) {
				sprite.pixels[i_1121_ + sprite.width * i] = is_1119_[i_1121_];
			}
		}
		aGraphicsBuffer_1201.method230(false);
		sprite.method470(0, 382);
		aGraphicsBuffer_1202.method230(false);
		sprite.method470(0, -255);
		aGraphicsBuffer_1198.method230(false);
		sprite.method470(0, 254);
		aGraphicsBuffer_1199.method230(false);
		sprite.method470(-371, 180);
		aGraphicsBuffer_1200.method230(false);
		sprite.method470(-171, 180);
		aGraphicsBuffer_1203.method230(false);
		if (bool) {
			for (int i = 1; i > 0; i++) {
				/* empty */
			}
		}
		sprite.method470(-265, 382);
		aGraphicsBuffer_1204.method230(false);
		sprite.method470(-265, -180);
		aGraphicsBuffer_1205.method230(false);
		sprite.method470(-171, 254);
		aGraphicsBuffer_1206.method230(false);
		sprite.method470(-171, -180);
		sprite = new Sprite(aArchive_888, "logo", 0);
		aGraphicsBuffer_1198.method230(false);
		sprite.drawSprite(382 - sprite.width / 2 - 128, 18);
		Object object = null;
		Object object_1122_ = null;
		Object object_1123_ = null;
		System.gc();
	}

	private final void method140(byte i, Class50_Sub2 class50_sub2) {
		int i_1124_ = 0;
		int i_1125_ = -1;
		int i_1126_ = 0;
		int i_1127_ = 0;
		if (i != -61) {
			aPacket_964.putByte(175);
		}
		if (class50_sub2.anInt1392 == 0) {
			i_1124_ = aClass22_1164.method267(class50_sub2.anInt1391, class50_sub2.anInt1393,
				class50_sub2.anInt1394);
		}
		if (class50_sub2.anInt1392 == 1) {
			i_1124_ = aClass22_1164.method268(class50_sub2.anInt1393, (byte) 4,
				class50_sub2.anInt1391, class50_sub2.anInt1394);
		}
		if (class50_sub2.anInt1392 == 2) {
			i_1124_ = aClass22_1164.method269(class50_sub2.anInt1391, class50_sub2.anInt1393,
				class50_sub2.anInt1394);
		}
		if (class50_sub2.anInt1392 == 3) {
			i_1124_ = aClass22_1164.method270(class50_sub2.anInt1391, class50_sub2.anInt1393,
				class50_sub2.anInt1394);
		}
		if (i_1124_ != 0) {
			int i_1128_ = aClass22_1164.method271(class50_sub2.anInt1391, class50_sub2.anInt1393,
				class50_sub2.anInt1394, i_1124_);
			i_1125_ = i_1124_ >> 14 & 0x7fff;
			i_1126_ = i_1128_ & 0x1f;
			i_1127_ = i_1128_ >> 6;
		}
		class50_sub2.anInt1387 = i_1125_;
		class50_sub2.anInt1389 = i_1126_;
		class50_sub2.anInt1388 = i_1127_;
	}

	public final void method141(int i) {
		aBoolean1243 = false;
		while (aBoolean1320) {
			aBoolean1243 = false;
			try {
				Thread.sleep(50L);
			} catch (Exception exception) {
				/* empty */
			}
		}
		aIndexedSprite_1292 = null;
		aIndexedSprite_1293 = null;
		aIndexedSpriteArray1117 = null;
		anIntArray1310 = null;
		anIntArray1311 = null;
		if (i != 28614) {
			aBoolean1074 = !aBoolean1074;
		}
		anIntArray1312 = null;
		anIntArray1313 = null;
		anIntArray1176 = null;
		anIntArray1177 = null;
		anIntArray1084 = null;
		anIntArray1085 = null;
		aSprite_1017 = null;
		aSprite_1018 = null;
	}

	public final void method142(int i, int i_1129_, Interface iComponent, int i_1130_, int i_1131_) {
		if (iComponent.anInt236 == 0
			&& iComponent.anIntArray258 != null
			&& (!iComponent.aBoolean219 || anInt1302 == iComponent.anInt215
				|| anInt1280 == iComponent.anInt215 || anInt1106 == iComponent.anInt215)) {
			int i_1132_ = Renderer2D.topX;
			int i_1133_ = Renderer2D.topY;
			int i_1134_ = Renderer2D.bottomX;
			int i_1135_ = Renderer2D.bottomY;
			Renderer2D.method457(i, i_1129_, i + iComponent.anInt238,
				i_1129_ + iComponent.anInt241, true);
			int i_1136_ = iComponent.anIntArray258.length;
			if (i_1131_ != 8) {
				opcode = -1;
			}
			for (int i_1137_ = 0; i_1137_ < i_1136_; i_1137_++) {
				int i_1138_ = iComponent.anIntArray232[i_1137_] + i_1129_;
				int i_1139_ = iComponent.anIntArray276[i_1137_] + i - i_1130_;
				Interface iComponent_1140_ = Interface.method195(iComponent.anIntArray258[i_1137_]);
				i_1138_ += iComponent_1140_.anInt228;
				i_1139_ += iComponent_1140_.anInt259;
				if (iComponent_1140_.anInt242 > 0) {
					method103((byte) 2, iComponent_1140_);
				}
				if (iComponent_1140_.anInt236 == 0) {
					if (iComponent_1140_.anInt231 > iComponent_1140_.anInt285
						- iComponent_1140_.anInt238) {
						iComponent_1140_.anInt231 = iComponent_1140_.anInt285
							- iComponent_1140_.anInt238;
					}
					if (iComponent_1140_.anInt231 < 0) {
						iComponent_1140_.anInt231 = 0;
					}
					method142(i_1139_, i_1138_, iComponent_1140_, iComponent_1140_.anInt231, 8);
					if (iComponent_1140_.anInt285 > iComponent_1140_.anInt238) {
						method56(true, iComponent_1140_.anInt231, i_1138_
							+ iComponent_1140_.anInt241, iComponent_1140_.anInt238,
							iComponent_1140_.anInt285, i_1139_);
					}
				} else if (iComponent_1140_.anInt236 != 1) {
					if (iComponent_1140_.anInt236 == 2) {
						int i_1141_ = 0;
						for (int i_1142_ = 0; i_1142_ < iComponent_1140_.anInt238; i_1142_++) {
							for (int i_1143_ = 0; i_1143_ < iComponent_1140_.anInt241; i_1143_++) {
								int i_1144_ = (i_1138_ + i_1143_ * (iComponent_1140_.anInt263 + 32));
								int i_1145_ = (i_1139_ + i_1142_ * (iComponent_1140_.anInt244 + 32));
								if (i_1141_ < 20) {
									i_1144_ += (iComponent_1140_.anIntArray221[i_1141_]);
									i_1145_ += (iComponent_1140_.anIntArray213[i_1141_]);
								}
								if (iComponent_1140_.anIntArray269[i_1141_] > 0) {
									int i_1146_ = 0;
									int i_1147_ = 0;
									int i_1148_ = (iComponent_1140_.anIntArray269[i_1141_] - 1);
									if (((i_1144_ > Renderer2D.topX - 32)
										&& (i_1144_ < Renderer2D.bottomX)
										&& i_1145_ > (Renderer2D.topY) - 32 && (i_1145_ < Renderer2D.bottomY))
										|| (anInt1113 != 0 && anInt1112 == i_1141_)) {
										int i_1149_ = 0;
										if (anInt1146 == 1 && anInt1147 == i_1141_
											&& (anInt1148 == iComponent_1140_.anInt215)) {
											i_1149_ = 16777215;
										}
										Sprite sprite = ItemDefinition.method221((byte) -33,
											i_1149_, (iComponent_1140_.anIntArray224[i_1141_]),
											i_1148_);
										if (sprite != null) {
											if (anInt1113 != 0 && anInt1112 == i_1141_
												&& anInt1111 == (iComponent_1140_.anInt215)) {
												i_1146_ = anInt22 - anInt1114;
												i_1147_ = anInt23 - anInt1115;
												if (i_1146_ < 5 && i_1146_ > -5) {
													i_1146_ = 0;
												}
												if (i_1147_ < 5 && i_1147_ > -5) {
													i_1147_ = 0;
												}
												if (anInt1269 < 5) {
													i_1146_ = 0;
													i_1147_ = 0;
												}
												sprite.method474(0, i_1144_ + i_1146_, i_1145_
													+ i_1147_, 128);
												if ((i_1145_ + i_1147_ < (Renderer2D.topY))
													&& iComponent.anInt231 > 0) {
													int i_1150_ = (anInt951
														* ((Renderer2D.topY) - i_1145_ - i_1147_) / 3);
													if (i_1150_ > anInt951 * 10) {
														i_1150_ = anInt951 * 10;
													}
													if (i_1150_ > iComponent.anInt231) {
														i_1150_ = iComponent.anInt231;
													}
													iComponent.anInt231 -= i_1150_;
													anInt1115 += i_1150_;
												}
												if ((i_1145_ + i_1147_ + 32 > (Renderer2D.bottomY))
													&& (iComponent.anInt231 < (iComponent.anInt285 - (iComponent.anInt238)))) {
													int i_1151_ = (anInt951
														* (i_1145_ + i_1147_ + 32 - (Renderer2D.bottomY)) / 3);
													if (i_1151_ > anInt951 * 10) {
														i_1151_ = anInt951 * 10;
													}
													if (i_1151_ > (iComponent.anInt285
														- iComponent.anInt238 - iComponent.anInt231)) {
														i_1151_ = (iComponent.anInt285
															- (iComponent.anInt238) - (iComponent.anInt231));
													}
													iComponent.anInt231 += i_1151_;
													anInt1115 -= i_1151_;
												}
											} else if (anInt1332 != 0 && anInt1331 == i_1141_
												&& (anInt1330 == (iComponent_1140_.anInt215))) {
												sprite.method474(0, i_1144_, i_1145_, 128);
											} else {
												sprite.drawSprite(i_1144_, i_1145_);
											}
											if ((sprite.trimWidth) == 33
												|| (iComponent_1140_.anIntArray224[i_1141_]) != 1) {
												int i_1152_ = (iComponent_1140_.anIntArray224[i_1141_]);
												aFont_1059.method485(2245, i_1144_ + 1 + i_1146_,
													0, i_1145_ + 10 + i_1147_,
													Client.method20(i_1152_, -243));
												aFont_1059.method485(2245, i_1144_ + i_1146_,
													16776960, i_1145_ + 9 + i_1147_,
													Client.method20(i_1152_, -243));
											}
										}
									}
								} else if (((iComponent_1140_.aSpriteArray265) != null)
									&& i_1141_ < 20) {
									Sprite sprite = (iComponent_1140_.aSpriteArray265[i_1141_]);
									if (sprite != null) {
										sprite.drawSprite(i_1144_, i_1145_);
									}
								}
								i_1141_++;
							}
						}
					} else if (iComponent_1140_.anInt236 == 3) {
						boolean bool = false;
						if (anInt1106 == iComponent_1140_.anInt215
							|| anInt1280 == iComponent_1140_.anInt215
							|| anInt1302 == iComponent_1140_.anInt215) {
							bool = true;
						}
						int i_1153_;
						if (method95(iComponent_1140_, -693)) {
							i_1153_ = iComponent_1140_.anInt260;
							if (bool && iComponent_1140_.anInt226 != 0) {
								i_1153_ = iComponent_1140_.anInt226;
							}
						} else {
							i_1153_ = iComponent_1140_.anInt240;
							if (bool && iComponent_1140_.anInt261 != 0) {
								i_1153_ = iComponent_1140_.anInt261;
							}
						}
						if (iComponent_1140_.aByte220 == 0) {
							if (iComponent_1140_.aBoolean239) {
								Renderer2D.method460(iComponent_1140_.anInt238, i_1139_, i_1153_,
									(byte) -24, iComponent_1140_.anInt241, i_1138_);
							} else {
								Renderer2D.method461(0, i_1139_, iComponent_1140_.anInt238,
									i_1153_, i_1138_, iComponent_1140_.anInt241);
							}
						} else if (iComponent_1140_.aBoolean239) {
							Renderer2D.method459(false, i_1153_, i_1139_,
								iComponent_1140_.anInt241, iComponent_1140_.anInt238,
								256 - ((iComponent_1140_.aByte220) & 0xff), i_1138_);
						} else {
							Renderer2D.method462(i_1138_, iComponent_1140_.anInt241, i_1153_,
								iComponent_1140_.anInt238, i_1139_,
								256 - (iComponent_1140_.aByte220 & 0xff), (byte) -113);
						}
					} else if (iComponent_1140_.anInt236 == 4) {
						Font font = iComponent_1140_.aFont_237;
						String string = iComponent_1140_.aString230;
						boolean bool = false;
						if (anInt1106 == iComponent_1140_.anInt215
							|| anInt1280 == iComponent_1140_.anInt215
							|| anInt1302 == iComponent_1140_.anInt215) {
							bool = true;
						}
						int i_1154_;
						if (method95(iComponent_1140_, -693)) {
							i_1154_ = iComponent_1140_.anInt260;
							if (bool && iComponent_1140_.anInt226 != 0) {
								i_1154_ = iComponent_1140_.anInt226;
							}
							if (iComponent_1140_.aString249.length() > 0) {
								string = iComponent_1140_.aString249;
							}
						} else {
							i_1154_ = iComponent_1140_.anInt240;
							if (bool && iComponent_1140_.anInt261 != 0) {
								i_1154_ = iComponent_1140_.anInt261;
							}
						}
						if (iComponent_1140_.anInt289 == 6 && aBoolean1239) {
							string = "Please wait...";
							i_1154_ = iComponent_1140_.anInt240;
						}
						if (Renderer2D.width == 479) {
							if (i_1154_ == 16776960) {
								i_1154_ = 255;
							}
							if (i_1154_ == 49152) {
								i_1154_ = 16777215;
							}
						}
						int i_1155_ = i_1139_ + font.anInt1506;
						while (string.length() > 0) {
							if (string.indexOf("%") != -1) {
								for (;;) {
									int i_1156_ = string.indexOf("%1");
									if (i_1156_ == -1) {
										break;
									}
									string = (string.substring(0, i_1156_)
										+ method89(method129(3, 0, iComponent_1140_), 8) + string
										.substring(i_1156_ + 2));
								}
								for (;;) {
									int i_1157_ = string.indexOf("%2");
									if (i_1157_ == -1) {
										break;
									}
									string = (string.substring(0, i_1157_)
										+ method89(method129(3, 1, iComponent_1140_), 8) + string
										.substring(i_1157_ + 2));
								}
								for (;;) {
									int i_1158_ = string.indexOf("%3");
									if (i_1158_ == -1) {
										break;
									}
									string = (string.substring(0, i_1158_)
										+ method89(method129(3, 2, iComponent_1140_), 8) + string
										.substring(i_1158_ + 2));
								}
								for (;;) {
									int i_1159_ = string.indexOf("%4");
									if (i_1159_ == -1) {
										break;
									}
									string = (string.substring(0, i_1159_)
										+ method89(method129(3, 3, iComponent_1140_), 8) + string
										.substring(i_1159_ + 2));
								}
								for (;;) {
									int i_1160_ = string.indexOf("%5");
									if (i_1160_ == -1) {
										break;
									}
									string = (string.substring(0, i_1160_)
										+ method89(method129(3, 4, iComponent_1140_), 8) + string
										.substring(i_1160_ + 2));
								}
							}
							int i_1161_ = string.indexOf("\\n");
							String string_1162_;
							if (i_1161_ != -1) {
								string_1162_ = string.substring(0, i_1161_);
								string = string.substring(i_1161_ + 2);
							} else {
								string_1162_ = string;
								string = "";
							}
							if (iComponent_1140_.aBoolean272) {
								font.method482(iComponent_1140_.aBoolean247, i_1154_, i_1155_,
									i_1138_ + iComponent_1140_.anInt241 / 2, string_1162_);
							} else {
								font.method489(i_1154_, i_1138_, i_1155_,
									iComponent_1140_.aBoolean247, string_1162_, -39629);
							}
							i_1155_ += font.anInt1506;
						}
					} else if (iComponent_1140_.anInt236 == 5) {
						Sprite sprite;
						if (method95(iComponent_1140_, -693)) {
							sprite = iComponent_1140_.aSprite_245;
						} else {
							sprite = iComponent_1140_.aSprite_212;
						}
						if (sprite != null) {
							sprite.drawSprite(i_1138_, i_1139_);
						}
					} else if (iComponent_1140_.anInt236 == 6) {
						int i_1163_ = Renderer3D.anInt1532;
						int i_1164_ = Renderer3D.anInt1533;
						Renderer3D.anInt1532 = i_1138_ + iComponent_1140_.anInt241 / 2;
						Renderer3D.anInt1533 = i_1139_ + iComponent_1140_.anInt238 / 2;
						int i_1165_ = (((Renderer3D.anIntArray1536[iComponent_1140_.anInt252]) * iComponent_1140_.anInt251) >> 16);
						int i_1166_ = (((Renderer3D.anIntArray1537[iComponent_1140_.anInt252]) * iComponent_1140_.anInt251) >> 16);
						boolean bool = method95(iComponent_1140_, -693);
						int i_1167_;
						if (bool) {
							i_1167_ = iComponent_1140_.anInt287;
						} else {
							i_1167_ = iComponent_1140_.anInt286;
						}
						Model model;
						if (i_1167_ == -1) {
							model = iComponent_1140_.method203(-1, -1, 0, bool);
						} else {
							Sequence sequence = Sequence.sequences[i_1167_];
							model = iComponent_1140_.method203(
								(sequence.anIntArray295[(iComponent_1140_.anInt235)]),
								(sequence.anIntArray296[(iComponent_1140_.anInt235)]), 0, bool);
						}
						if (model != null) {
							model.method609(0, iComponent_1140_.anInt253, 0,
								iComponent_1140_.anInt252, 0, i_1165_, i_1166_);
						}
						Renderer3D.anInt1532 = i_1163_;
						Renderer3D.anInt1533 = i_1164_;
					} else {
						if (iComponent_1140_.anInt236 == 7) {
							Font font = iComponent_1140_.aFont_237;
							int i_1168_ = 0;
							for (int i_1169_ = 0; i_1169_ < iComponent_1140_.anInt238; i_1169_++) {
								for (int i_1170_ = 0; i_1170_ < iComponent_1140_.anInt241; i_1170_++) {
									if (iComponent_1140_.anIntArray269[i_1168_] > 0) {
										ItemDefinition itemDefinition = ItemDefinition
											.method212((iComponent_1140_.anIntArray269[i_1168_]) - 1);
										String string = itemDefinition.examine;
										if (itemDefinition.aBoolean371
											|| (iComponent_1140_.anIntArray224[i_1168_]) != 1) {
											string += (" x" + Client.method135(0,
												(iComponent_1140_.anIntArray224[i_1168_])));
										}
										int i_1171_ = (i_1138_ + (i_1170_ * (iComponent_1140_.anInt263 + 115)));
										int i_1172_ = (i_1139_ + (i_1169_ * (iComponent_1140_.anInt244 + 12)));
										if (iComponent_1140_.aBoolean272) {
											font.method482(iComponent_1140_.aBoolean247,
												iComponent_1140_.anInt240, i_1172_, i_1171_
													+ (iComponent_1140_.anInt241) / 2, string);
										} else {
											font.method489(iComponent_1140_.anInt240, i_1171_,
												i_1172_, iComponent_1140_.aBoolean247, string,
												-39629);
										}
									}
									i_1168_++;
								}
							}
						}
						if (iComponent_1140_.anInt236 == 8
							&& (anInt1284 == iComponent_1140_.anInt215
								|| anInt1044 == iComponent_1140_.anInt215 || anInt1129 == iComponent_1140_.anInt215)
							&& anInt893 == 100) {
							int i_1173_ = 0;
							int i_1174_ = 0;
							Font font = aFont_1060;
							String string = iComponent_1140_.aString230;
							while (string.length() > 0) {
								int i_1175_ = string.indexOf("\\n");
								String string_1176_;
								if (i_1175_ != -1) {
									string_1176_ = string.substring(0, i_1175_);
									string = string.substring(i_1175_ + 2);
								} else {
									string_1176_ = string;
									string = "";
								}
								int i_1177_ = font.method483((byte) 35, string_1176_);
								if (i_1177_ > i_1173_) {
									i_1173_ = i_1177_;
								}
								i_1174_ += font.anInt1506 + 1;
							}
							i_1173_ += 6;
							i_1174_ += 7;
							int i_1178_ = (i_1138_ + iComponent_1140_.anInt241 - 5 - i_1173_);
							int i_1179_ = i_1139_ + iComponent_1140_.anInt238 + 5;
							if (i_1178_ < i_1138_ + 5) {
								i_1178_ = i_1138_ + 5;
							}
							if (i_1178_ + i_1173_ > i_1129_ + iComponent.anInt241) {
								i_1178_ = i_1129_ + iComponent.anInt241 - i_1173_;
							}
							if (i_1179_ + i_1174_ > i + iComponent.anInt238) {
								i_1179_ = i + iComponent.anInt238 - i_1174_;
							}
							Renderer2D.method460(i_1174_, i_1179_, 16777120, (byte) -24, i_1173_,
								i_1178_);
							Renderer2D.method461(0, i_1179_, i_1174_, 0, i_1178_, i_1173_);
							string = iComponent_1140_.aString230;
							int i_1180_ = (i_1179_ + font.anInt1506 + 2);
							while (string.length() > 0) {
								int i_1181_ = string.indexOf("\\n");
								String string_1182_;
								if (i_1181_ != -1) {
									string_1182_ = string.substring(0, i_1181_);
									string = string.substring(i_1181_ + 2);
								} else {
									string_1182_ = string;
									string = "";
								}
								font.method489(0, i_1178_ + 3, i_1180_, false, string_1182_, -39629);
								i_1180_ += font.anInt1506 + 1;
							}
						}
					}
				}
			}
			Renderer2D.method457(i_1133_, i_1132_, i_1135_, i_1134_, true);
		}
	}

	public final void method143(byte i) {
		if (i != -40) {
			Client.aBoolean1207 = !Client.aBoolean1207;
		}
		if (Client.aBoolean926 && anInt1071 == 2 && Class8.anInt162 != anInt1091) {
			method125(-332, null, "Loading - please wait.");
			anInt1071 = 1;
			aLong1229 = System.currentTimeMillis();
		}
		if (anInt1071 == 1) {
			int i_1183_ = method144(5);
			if (i_1183_ != 0 && System.currentTimeMillis() - aLong1229 > 360000L) {
				Signlink.reporterror(aString1092 + " glcfb " + aLong930 + "," + i_1183_ + ","
					+ Client.aBoolean926 + "," + ((Client) this).aCacheIndexArray1228[0] + ","
					+ aClass32_Sub1_1291.method333() + "," + anInt1091 + "," + anInt889 + ","
					+ anInt890);
				aLong1229 = System.currentTimeMillis();
			}
		}
		if (anInt1071 == 2 && anInt1091 != anInt1276) {
			anInt1276 = anInt1091;
			method115(anInt1091, 0);
		}
	}

	public final int method144(int i) {
		for (int i_1184_ = 0; i_1184_ < aByteArrayArray838.length; i_1184_++) {
			if (aByteArrayArray838[i_1184_] == null && anIntArray857[i_1184_] != -1) {
				return -1;
			}
			if (aByteArrayArray1232[i_1184_] == null && anIntArray858[i_1184_] != -1) {
				return -2;
			}
		}
		boolean bool = true;
		if (i < 5 || i > 5) {
			aBoolean953 = !aBoolean953;
		}
		for (int i_1185_ = 0; i_1185_ < aByteArrayArray838.length; i_1185_++) {
			byte[] is = aByteArrayArray1232[i_1185_];
			if (is != null) {
				int i_1186_ = (anIntArray856[i_1185_] >> 8) * 64 - anInt1040;
				int i_1187_ = (anIntArray856[i_1185_] & 0xff) * 64 - anInt1041;
				if (aBoolean1163) {
					i_1186_ = 10;
					i_1187_ = 10;
				}
				bool &= Class8.method181(i_1186_, i_1187_, is, 24515);
			}
		}
		if (!bool) {
			return -3;
		}
		if (aBoolean1209) {
			return -4;
		}
		anInt1071 = 2;
		Class8.anInt162 = anInt1091;
		method93(175);
		aPacket_964.putOpcode(6);
		return 0;
	}

	private final void method145(boolean bool, int i, int i_1188_, int i_1189_, int i_1190_,
		int i_1191_, int i_1192_, int i_1193_, int i_1194_, int i_1195_) {
		Class50_Sub2 class50_sub2 = null;
		for (Class50_Sub2 class50_sub2_1196_ = (Class50_Sub2) aDeque_1261.method158(); class50_sub2_1196_ != null; class50_sub2_1196_ = (Class50_Sub2) aDeque_1261
			.method160(1)) {
			if (class50_sub2_1196_.anInt1391 == i && class50_sub2_1196_.anInt1393 == i_1188_
				&& class50_sub2_1196_.anInt1394 == i_1195_
				&& class50_sub2_1196_.anInt1392 == i_1194_) {
				class50_sub2 = class50_sub2_1196_;
				break;
			}
		}
		if (class50_sub2 == null) {
			class50_sub2 = new Class50_Sub2();
			class50_sub2.anInt1391 = i;
			class50_sub2.anInt1392 = i_1194_;
			class50_sub2.anInt1393 = i_1188_;
			class50_sub2.anInt1394 = i_1195_;
			method140((byte) -61, class50_sub2);
			aDeque_1261.method155(class50_sub2);
		}
		class50_sub2.anInt1384 = i_1192_;
		class50_sub2.anInt1386 = i_1191_;
		class50_sub2.anInt1385 = i_1189_;
		class50_sub2.anInt1395 = i_1193_;
		class50_sub2.anInt1390 = i_1190_;
		aBoolean1137 &= bool;
	}

	public final void method146(byte i) {
		if (i == 4 && anInt1050 == 0) {
			if (anInt28 == 1) {
				int i_1197_ = anInt29 - 25 - 550;
				int i_1198_ = anInt30 - 5 - 4;
				if (i_1197_ >= 0 && i_1198_ >= 0 && i_1197_ < 146 && i_1198_ < 151) {
					i_1197_ -= 73;
					i_1198_ -= 75;
					int i_1199_ = anInt1252 + anInt916 & 0x7ff;
					int i_1200_ = Renderer3D.anIntArray1536[i_1199_];
					int i_1201_ = Renderer3D.anIntArray1537[i_1199_];
					i_1200_ = i_1200_ * (anInt1233 + 256) >> 8;
					i_1201_ = i_1201_ * (anInt1233 + 256) >> 8;
					int i_1202_ = i_1198_ * i_1200_ + i_1197_ * i_1201_ >> 11;
					int i_1203_ = i_1198_ * i_1201_ - i_1197_ * i_1200_ >> 11;
					int i_1204_ = ((((ObjectInstance) Client.myPlayer).anInt1610)
						+ i_1202_ >> 7);
					int i_1205_ = ((((ObjectInstance) Client.myPlayer).anInt1611)
						- i_1203_ >> 7);
					boolean bool = method35(true, false, i_1205_,
						(((ObjectInstance) Client.myPlayer).anIntArray1587[0]), 0, 0,
						1, 0, i_1204_, 0, 0,
						(((ObjectInstance) Client.myPlayer).anIntArray1586[0]));
					if (bool) {
						aPacket_964.putByte(i_1197_);
						aPacket_964.putByte(i_1198_);
						aPacket_964.putShort(anInt1252);
						aPacket_964.putByte(57);
						aPacket_964.putByte(anInt916);
						aPacket_964.putByte(anInt1233);
						aPacket_964.putByte(89);
						aPacket_964
							.putShort(((ObjectInstance) Client.myPlayer).anInt1610);
						aPacket_964
							.putShort(((ObjectInstance) Client.myPlayer).anInt1611);
						aPacket_964.putByte(anInt1126);
						aPacket_964.putByte(63);
					}
				}
			}
		}
	}

	public final void method147(int i) {
		if (aGraphicsBuffer_15 == null) {
			method141(28614);
			aGraphicsBuffer_1198 = null;
			aGraphicsBuffer_1199 = null;
			aGraphicsBuffer_1200 = null;
			if (i >= 0) {
				anInt1004 = -4;
			}
			aGraphicsBuffer_1201 = null;
			aGraphicsBuffer_1202 = null;
			aGraphicsBuffer_1203 = null;
			aGraphicsBuffer_1204 = null;
			aGraphicsBuffer_1205 = null;
			aGraphicsBuffer_1206 = null;
			aGraphicsBuffer_1159 = null;
			aGraphicsBuffer_1157 = null;
			aGraphicsBuffer_1156 = null;
			aGraphicsBuffer_1158 = null;
			aGraphicsBuffer_1108 = null;
			aGraphicsBuffer_1109 = null;
			aGraphicsBuffer_1110 = null;
			aGraphicsBuffer_15 = new GraphicsBuffer(503, method11(), 765);
			aBoolean1046 = true;
		}
	}

	public final boolean method148(int i, String string) {
		if (string == null) {
			return false;
		}
		for (int i_1206_ = 0; i_1206_ < friendCount; i_1206_++) {
			if (string.equalsIgnoreCase(friendNames[i_1206_])) {
				return true;
			}
		}
		if (i != 13292) {
			aBoolean1014 = !aBoolean1014;
		}
		if (string.equalsIgnoreCase(((Player) Client.myPlayer).aString1751)) {
			return true;
		}
		return false;
	}

	public final void method149(int i) {
		while (i >= 0) {
			opcode = inputStream.getUByte();
		}
		do {
			if (anInt1225 == 0) {
				int i_1207_ = anInt12 / 2 - 80;
				int i_1208_ = anInt13 / 2 + 20;
				i_1208_ += 20;
				if (anInt28 == 1 && anInt29 >= i_1207_ - 75 && anInt29 <= i_1207_ + 75
					&& anInt30 >= i_1208_ - 20 && anInt30 <= i_1208_ + 20) {
					anInt1225 = 3;
					anInt977 = 0;
				}
				i_1207_ = anInt12 / 2 + 80;
				if (anInt28 == 1 && anInt29 >= i_1207_ - 75 && anInt29 <= i_1207_ + 75
					&& anInt30 >= i_1208_ - 20 && anInt30 <= i_1208_ + 20) {
					aString957 = "";
					aString958 = "Enter your username & password.";
					anInt1225 = 2;
					anInt977 = 0;
				}
			} else if (anInt1225 == 2) {
				int i_1209_ = anInt13 / 2 - 40;
				i_1209_ += 30;
				i_1209_ += 25;
				if (anInt28 == 1 && anInt30 >= i_1209_ - 15 && anInt30 < i_1209_) {
					anInt977 = 0;
				}
				i_1209_ += 15;
				if (anInt28 == 1 && anInt30 >= i_1209_ - 15 && anInt30 < i_1209_) {
					anInt977 = 1;
				}
				i_1209_ += 15;
				int i_1210_ = anInt12 / 2 - 80;
				int i_1211_ = anInt13 / 2 + 50;
				i_1211_ += 20;
				if (anInt28 == 1 && anInt29 >= i_1210_ - 75 && anInt29 <= i_1210_ + 75
					&& anInt30 >= i_1211_ - 20 && anInt30 <= i_1211_ + 20) {
					anInt850 = 0;
					method79(aString1092, aString1093, false);
					if (aBoolean1137) {
						break;
					}
				}
				i_1210_ = anInt12 / 2 + 80;
				if (anInt28 == 1 && anInt29 >= i_1210_ - 75 && anInt29 <= i_1210_ + 75
					&& anInt30 >= i_1211_ - 20 && anInt30 <= i_1211_ + 20) {
					anInt1225 = 0;
					aString1092 = "";
					aString1093 = "";
				}
				for (;;) {
					int i_1212_ = this.method5();
					if (i_1212_ == -1) {
						break;
					}
					boolean bool = false;
					for (int i_1213_ = 0; i_1213_ < Client.aString1007.length(); i_1213_++) {
						if (i_1212_ == Client.aString1007.charAt(i_1213_)) {
							bool = true;
							break;
						}
					}
					if (anInt977 == 0) {
						if (i_1212_ == 8 && aString1092.length() > 0) {
							aString1092 = aString1092.substring(0, aString1092.length() - 1);
						}
						if (i_1212_ == 9 || i_1212_ == 10 || i_1212_ == 13) {
							anInt977 = 1;
						}
						if (bool) {
							aString1092 += (char) i_1212_;
						}
						if (aString1092.length() > 12) {
							aString1092 = aString1092.substring(0, 12);
						}
					} else if (anInt977 == 1) {
						if (i_1212_ == 8 && aString1093.length() > 0) {
							aString1093 = aString1093.substring(0, aString1093.length() - 1);
						}
						if (i_1212_ == 9 || i_1212_ == 10 || i_1212_ == 13) {
							anInt977 = 0;
						}
						if (bool) {
							aString1093 += (char) i_1212_;
						}
						if (aString1093.length() > 20) {
							aString1093 = aString1093.substring(0, 20);
						}
					}
				}
			} else {
				if (anInt1225 != 3) {
					break;
				}
				int i_1214_ = anInt12 / 2;
				int i_1215_ = anInt13 / 2 + 50;
				i_1215_ += 20;
				if (anInt28 != 1 || anInt29 < i_1214_ - 75 || anInt29 > i_1214_ + 75
					|| anInt30 < i_1215_ - 20 || anInt30 > i_1215_ + 20) {
					break;
				}
				anInt1225 = 0;
			}
			break;
		} while (false);
	}

	public final void method150(int i, int i_1216_, int i_1217_, int i_1218_, int i_1219_,
		int i_1220_) {
		int i_1221_ = aClass22_1164.method267(i_1216_, i_1217_, i);
		i_1219_ = 62 / i_1219_;
		if (i_1221_ != 0) {
			int i_1222_ = aClass22_1164.method271(i_1216_, i_1217_, i, i_1221_);
			int i_1223_ = i_1222_ >> 6 & 0x3;
			int i_1224_ = i_1222_ & 0x1f;
			int i_1225_ = i_1220_;
			if (i_1221_ > 0) {
				i_1225_ = i_1218_;
			}
			int[] is = aSprite_1122.pixels;
			int i_1226_ = i_1217_ * 4 + 24624 + (103 - i) * 512 * 4;
			int i_1227_ = i_1221_ >> 14 & 0x7fff;
			ObjectDefinition objectDefinition = ObjectDefinition.method434(i_1227_);
			if (objectDefinition.anInt795 != -1) {
				IndexedSprite class50_sub1_sub1_sub3 = mapscenes[objectDefinition.anInt795];
				if (class50_sub1_sub1_sub3 != null) {
					int i_1228_ = ((objectDefinition.anInt801 * 4 - class50_sub1_sub1_sub3.width) / 2);
					int i_1229_ = ((objectDefinition.anInt775 * 4 - class50_sub1_sub1_sub3.anInt1519) / 2);
					class50_sub1_sub1_sub3.method501(48 + (104 - i - objectDefinition.anInt775) * 4
						+ i_1229_, i_1217_ * 4 + 48 + i_1228_);
				}
			} else {
				if (i_1224_ == 0 || i_1224_ == 2) {
					if (i_1223_ == 0) {
						is[i_1226_] = i_1225_;
						is[i_1226_ + 512] = i_1225_;
						is[i_1226_ + 1024] = i_1225_;
						is[i_1226_ + 1536] = i_1225_;
					} else if (i_1223_ == 1) {
						is[i_1226_] = i_1225_;
						is[i_1226_ + 1] = i_1225_;
						is[i_1226_ + 2] = i_1225_;
						is[i_1226_ + 3] = i_1225_;
					} else if (i_1223_ == 2) {
						is[i_1226_ + 3] = i_1225_;
						is[i_1226_ + 3 + 512] = i_1225_;
						is[i_1226_ + 3 + 1024] = i_1225_;
						is[i_1226_ + 3 + 1536] = i_1225_;
					} else if (i_1223_ == 3) {
						is[i_1226_ + 1536] = i_1225_;
						is[i_1226_ + 1536 + 1] = i_1225_;
						is[i_1226_ + 1536 + 2] = i_1225_;
						is[i_1226_ + 1536 + 3] = i_1225_;
					}
				}
				if (i_1224_ == 3) {
					if (i_1223_ == 0) {
						is[i_1226_] = i_1225_;
					} else if (i_1223_ == 1) {
						is[i_1226_ + 3] = i_1225_;
					} else if (i_1223_ == 2) {
						is[i_1226_ + 3 + 1536] = i_1225_;
					} else if (i_1223_ == 3) {
						is[i_1226_ + 1536] = i_1225_;
					}
				}
				if (i_1224_ == 2) {
					if (i_1223_ == 3) {
						is[i_1226_] = i_1225_;
						is[i_1226_ + 512] = i_1225_;
						is[i_1226_ + 1024] = i_1225_;
						is[i_1226_ + 1536] = i_1225_;
					} else if (i_1223_ == 0) {
						is[i_1226_] = i_1225_;
						is[i_1226_ + 1] = i_1225_;
						is[i_1226_ + 2] = i_1225_;
						is[i_1226_ + 3] = i_1225_;
					} else if (i_1223_ == 1) {
						is[i_1226_ + 3] = i_1225_;
						is[i_1226_ + 3 + 512] = i_1225_;
						is[i_1226_ + 3 + 1024] = i_1225_;
						is[i_1226_ + 3 + 1536] = i_1225_;
					} else if (i_1223_ == 2) {
						is[i_1226_ + 1536] = i_1225_;
						is[i_1226_ + 1536 + 1] = i_1225_;
						is[i_1226_ + 1536 + 2] = i_1225_;
						is[i_1226_ + 1536 + 3] = i_1225_;
					}
				}
			}
		}
		i_1221_ = aClass22_1164.method269(i_1216_, i_1217_, i);
		if (i_1221_ != 0) {
			int i_1230_ = aClass22_1164.method271(i_1216_, i_1217_, i, i_1221_);
			int i_1231_ = i_1230_ >> 6 & 0x3;
			int i_1232_ = i_1230_ & 0x1f;
			int i_1233_ = i_1221_ >> 14 & 0x7fff;
			ObjectDefinition objectDefinition = ObjectDefinition.method434(i_1233_);
			if (objectDefinition.anInt795 != -1) {
				IndexedSprite class50_sub1_sub1_sub3 = mapscenes[objectDefinition.anInt795];
				if (class50_sub1_sub1_sub3 != null) {
					int i_1234_ = ((objectDefinition.anInt801 * 4 - class50_sub1_sub1_sub3.width) / 2);
					int i_1235_ = ((objectDefinition.anInt775 * 4 - class50_sub1_sub1_sub3.anInt1519) / 2);
					class50_sub1_sub1_sub3.method501(48 + (104 - i - objectDefinition.anInt775) * 4
						+ i_1235_, i_1217_ * 4 + 48 + i_1234_);
				}
			} else if (i_1232_ == 9) {
				int i_1236_ = 15658734;
				if (i_1221_ > 0) {
					i_1236_ = 15597568;
				}
				int[] is = aSprite_1122.pixels;
				int i_1237_ = i_1217_ * 4 + 24624 + (103 - i) * 512 * 4;
				if (i_1231_ == 0 || i_1231_ == 2) {
					is[i_1237_ + 1536] = i_1236_;
					is[i_1237_ + 1024 + 1] = i_1236_;
					is[i_1237_ + 512 + 2] = i_1236_;
					is[i_1237_ + 3] = i_1236_;
				} else {
					is[i_1237_] = i_1236_;
					is[i_1237_ + 512 + 1] = i_1236_;
					is[i_1237_ + 1024 + 2] = i_1236_;
					is[i_1237_ + 1536 + 3] = i_1236_;
				}
			}
		}
		i_1221_ = aClass22_1164.method270(i_1216_, i_1217_, i);
		if (i_1221_ != 0) {
			int i_1238_ = i_1221_ >> 14 & 0x7fff;
			ObjectDefinition objectDefinition = ObjectDefinition.method434(i_1238_);
			if (objectDefinition.anInt795 != -1) {
				IndexedSprite class50_sub1_sub1_sub3 = mapscenes[objectDefinition.anInt795];
				if (class50_sub1_sub1_sub3 != null) {
					int i_1239_ = ((objectDefinition.anInt801 * 4 - class50_sub1_sub1_sub3.width) / 2);
					int i_1240_ = ((objectDefinition.anInt775 * 4 - class50_sub1_sub1_sub3.anInt1519) / 2);
					class50_sub1_sub1_sub3.method501(48 + (104 - i - objectDefinition.anInt775) * 4
						+ i_1240_, i_1217_ * 4 + 48 + i_1239_);
				}
			}
		}
	}

	public final void method151(int i) {
		anInt1138++;
		method119(0, true);
		method57(751, true);
		method119(0, false);
		method57(751, false);
		method51(false);
		method76(-992);
		if (!aBoolean1211) {
			int i_1241_ = anInt1251;
			if (anInt1289 / 256 > i_1241_) {
				i_1241_ = anInt1289 / 256;
			}
			if (aBooleanArray927[4] && anIntArray852[4] + 128 > i_1241_) {
				i_1241_ = anIntArray852[4] + 128;
			}
			int i_1242_ = anInt1252 + anInt1255 & 0x7ff;
			method94(
				method110(((ObjectInstance) Client.myPlayer).anInt1611,
					((ObjectInstance) Client.myPlayer).anInt1610, (byte) 9, anInt1091) - 50,
				anInt1262, i_1241_, i_1241_ * 3 + 600, i_1242_, anInt1263, (byte) -103);
		}
		int i_1243_;
		if (!aBoolean1211) {
			i_1243_ = method117((byte) 1);
		} else {
			i_1243_ = method118(-276);
		}
		int i_1244_ = anInt1216;
		int i_1245_ = anInt1217;
		int i_1246_ = anInt1218;
		int i_1247_ = anInt1219;
		int i_1248_ = anInt1220;
		if (i != 2) {
			anInt1004 = cryption.getNextKey();
		}
		for (int i_1249_ = 0; i_1249_ < 5; i_1249_++) {
			if (aBooleanArray927[i_1249_]) {
				int i_1250_ = (int) ((Math.random() * (double) (anIntArray1105[i_1249_] * 2 + 1))
					- (double) anIntArray1105[i_1249_] + (Math.sin((double) anIntArray1145[i_1249_]
					* ((double) anIntArray991[i_1249_] / 100.0)) * (double) anIntArray852[i_1249_]));
				if (i_1249_ == 0) {
					anInt1216 += i_1250_;
				}
				if (i_1249_ == 1) {
					anInt1217 += i_1250_;
				}
				if (i_1249_ == 2) {
					anInt1218 += i_1250_;
				}
				if (i_1249_ == 3) {
					anInt1220 = anInt1220 + i_1250_ & 0x7ff;
				}
				if (i_1249_ == 4) {
					anInt1219 += i_1250_;
					if (anInt1219 < 128) {
						anInt1219 = 128;
					}
					if (anInt1219 > 383) {
						anInt1219 = 383;
					}
				}
			}
		}
		int i_1251_ = Renderer3D.anInt1547;
		Model.aBoolean1705 = true;
		Model.anInt1708 = 0;
		Model.anInt1706 = anInt22 - 4;
		Model.anInt1707 = anInt23 - 4;
		Renderer2D.method458(4);
		aClass22_1164.method280(anInt1216, i_1243_, 0, anInt1217, anInt1218, anInt1220, anInt1219);
		aClass22_1164.method255(anInt897);
		updateEntites();
		method127();
		method65(i_1251_, -927);
		method109(30729);
		aGraphicsBuffer_1158.method231(4, 4, aGraphics14, aBoolean1074);
		anInt1216 = i_1244_;
		anInt1217 = i_1245_;
		anInt1218 = i_1246_;
		anInt1219 = i_1247_;
		anInt1220 = i_1248_;
	}

	public final void method152(int i) {
		if (i != -23763) {
			method6();
		}
		for (int i_1252_ = 0; i_1252_ < anInt1035; i_1252_++) {
			if (anIntArray1259[i_1252_] <= 0) {
				boolean bool = false;
				try {
					if (anIntArray1090[i_1252_] == anInt1272 && anIntArray1321[i_1252_] == anInt935) {
						if (!method78(295)) {
							bool = true;
						}
					} else {
						Packet packet = Class38.method377(anIntArray1321[i_1252_], (byte) 6,
							anIntArray1090[i_1252_]);
						if ((System.currentTimeMillis() + (long) (packet.offset / 22)) > aLong1250
							+ (long) (anInt1179 / 22)) {
							anInt1179 = packet.offset;
							aLong1250 = System.currentTimeMillis();
							if (method116(3, packet.offset, packet.payload)) {
								anInt1272 = anIntArray1090[i_1252_];
								anInt935 = anIntArray1321[i_1252_];
							} else {
								bool = true;
							}
						}
					}
				} catch (Exception exception) {
					if (Signlink.reporterror) {
						aPacket_964.putOpcode(80);
						aPacket_964.putShort(anIntArray1090[i_1252_] & 0x7fff);
					} else {
						aPacket_964.putOpcode(80);
						aPacket_964.putShort(-1);
					}
				}
				if (!bool || anIntArray1259[i_1252_] == -5) {
					anInt1035--;
					for (int i_1253_ = i_1252_; i_1253_ < anInt1035; i_1253_++) {
						anIntArray1090[i_1253_] = anIntArray1090[i_1253_ + 1];
						anIntArray1321[i_1253_] = anIntArray1321[i_1253_ + 1];
						anIntArray1259[i_1253_] = anIntArray1259[i_1253_ + 1];
					}
					i_1252_--;
				} else {
					anIntArray1259[i_1252_] = -5;
				}
			} else {
				anIntArray1259[i_1252_]--;
			}
		}
		if (anInt1128 > 0) {
			anInt1128 -= 20;
			if (anInt1128 < 0) {
				anInt1128 = 0;
			}
			if (anInt1128 == 0 && aBoolean1266 && !Client.aBoolean926) {
				anInt1270 = anInt1327;
				aBoolean1271 = true;
				aClass32_Sub1_1291.method329(2, anInt1270);
			}
		}
	}
	static {
		int i = 0;
		for (int i_1254_ = 0; i_1254_ < 99; i_1254_++) {
			int i_1255_ = i_1254_ + 1;
			int i_1256_ = (int) ((double) i_1255_ + 300.0 * Math.pow(2.0, (double) i_1255_ / 7.0));
			i += i_1256_;
			Client.anIntArray952[i_1254_] = i / 4;
		}
		Client.aBoolean963 = true;
		Client.aString1007 = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789!\"\u00a3$%^&*()-_=+[{]};:'@#~,<.>/?\\| ";
		anIntArrayArray1008 = (new int[][] {
			{ 6798, 107, 10283, 16, 4797, 7744, 5799, 4634, 33697, 22433, 2983, 54193 },
			{ 8741, 12, 64030, 43162, 7735, 8404, 1701, 38430, 24094, 10153, 56621, 4783, 1341,
				16578, 35003, 25239 },
			{ 25238, 8742, 12, 64030, 43162, 7735, 8404, 1701, 38430, 24094, 10153, 56621, 4783,
				1341, 16578, 35003 }, { 4626, 11146, 6439, 12, 4758, 10270 },
			{ 4550, 4537, 5681, 5673, 5790, 6806, 8076, 4574 } });
		Client.anInt1025 = -352;
		Client.aBoolean1190 = true;
		Client.anIntArray1214 = new int[32];
		i = 2;
		for (int i_1257_ = 0; i_1257_ < 32; i_1257_++) {
			Client.anIntArray1214[i_1257_] = i - 1;
			i += i;
		}
		Client.aBoolean1242 = true;
		anIntArray1268 = new int[] { 9104, 10275, 7595, 3610, 7975, 8526, 918, 38802, 24466, 10145,
			58654, 5027, 1457, 16565, 34991, 25486 };
		Client.aBigInteger1316 = (new BigInteger(
			"58778699976184461502525193738213253649000149147835990136706041084440742975821"));
	}
}
